📄 top.php
字号:
<?php
include_once( "inc/global.inc" );
include_once( $GLOBALEL['root_lib']."Template.inc" );
include_once( $GLOBALEL['root_lib']."SymsDb.inc" );
include_once( "inc/common.inc" );
include_once( "inc/auth.php" );
include_once( "inc/utility.php" );
require_once( "include/index.inc" );
session_cache_limiter( "private, must-revalidate" );
session_start( );
$term = true;
$msg = "";
while ( $term )
{
if ( !isset( $edb ) || !is_object( $edb ) )
{
$edb = "";
if ( !com_opendb( $edb, $GLOBALEL['db_debug'] ) )
{
$term = false;
$error = "8600900000000001";
break;
}
}
if ( !isset( $_REQUEST['step'] ) )
{
$step = 1;
}
else
{
$step = $_REQUEST['step'];
}
if ( !( $step == 1 ) )
{
break;
}
$parr['user_id'] = $_SESSION['LOGIN_USER_ID'];
$result = array( );
if ( !( $result = dml_topicuser( $edb, $nd, $einfo, $parr ) ) && $nd === false )
{
$msg = $einfo;
$term = false;
break;
}
$res_cnt = count( $result );
$i = 0;
for ( ; $i < $res_cnt; ++$i )
{
$tborderid[$i] = $result[$i]['BOARD'];
}
$res = array( );
if ( !( $res = dml_boardinfo( $edb, $nd, $einfo, $parr ) ) )
{
$msg = $einfo;
$term = false;
}
else
{
$i = 0;
for ( ; $i < count( $res ); ++$i )
{
if ( find_id( $res[$i]['MANAGER'], $_SESSION['LOGIN_USER_ID'] ) )
{
$SAFE_CHECK_OK = 1;
$mborderid[$i] = $res[$i]['ID'];
}
}
if ( $tborderid[0] != "" && $mborderid[0] != "" )
{
$boardid = array_merge( $tborderid, $mborderid );
}
else if ( $tborderid[0] != "" && $mborderid[0] == "" )
{
$boardid = $tborderid;
}
else if ( $tborderid[0] == "" && $mborderid[0] != "" )
{
$boardid = $mborderid;
}
$bres = array( );
if ( !( $boardid != "" ) )
{
break;
}
$parr['board_id'] = implode( ",", $boardid );
if ( !( $bres = dml_sboardinfo( $edb, $nd, $einfo, $parr ) ) && $nd === false )
{
$term = false;
$msg = $einfo;
break;
}
$bres_cnt = count( $bres );
break;
}
}
if ( isset( $edb ) && is_object( $edb ) )
{
@com_closedb( $edb, $term );
}
$fa = array( );
$fa['fh'] = "base.html";
$t = new template( $GLOBALEL['root_tpl'] );
while ( !$term && !( $step == 1 ) )
{
$fa['fh_main'] = "cooperation/top.htm";
$t->set_file( $fa );
$t->set_block( "fh_main", "boardlist_block", "boardlist_blk" );
$i = 0;
for ( ; $i < count( $bres ); ++$i )
{
$t->set_var( "VAR_COUNT", count( $bres ) );
$t->set_var( "VAR_I", $i + 1 );
$t->set_var( "VAR_ID", $bres[$i]['ID'] );
$t->set_var( "VAR_TITLE", $bres[$i]['TITLE'] );
$t->parse( "boardlist_blk", "boardlist_block", true );
}
if ( !( count( $bres ) == 0 ) )
{
break;
}
$t->set_var( "VAR_COUNT", 0 );
break;
}
if ( !$term )
{
$fa['fh_error'] = "error.html";
$t->set_file( $fa );
$t->set_var( "BODY_MAIN", "" );
$t->set_var( "VAR_ERROR_MSG", com_addappendixhref( $msg ) );
$t->parse( "BODY_ERROR", "fh_error" );
}
else
{
$t->set_var( "BODY_ERROR", "" );
$t->parse( "BODY_MAIN", "fh_main" );
}
$t->parse( "final_output", "fh" );
$t->p( "final_output" );
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -