📄 group_xml.php
字号:
<?php
session_start( );
include_once( "inc/conn.php" );
include_once( "inc/xtree_xml.inc.php" );
include_once( "inc/utility_all.php" );
header( "Expires: Mon, 26 Jul 1997 05:00:00 GMT" );
header( "Cache-Control: no-cache, must-revalidate" );
header( "Pragma: no-cache" );
header( "Content-Type: text/xml" );
$pararr = explodestpar( $_REQUEST['par'] );
$groupid = $pararr['groupid'];
if ( $groupid == "" )
{
exit( );
}
$groupurl_fix = "?";
$userurl_fix = "?";
if ( 0 < strpos( $pararr['group_url'], "?" ) )
{
$groupurl_fix = "&";
}
if ( 0 < strpos( $pararr['user_url'], "?" ) )
{
$userurl_fix = "&";
}
$xtreeXml = new xtreexml( );
$xtreeXml->initxml( );
$sql = "SELECT * FROM USER,USER_GROUP WHERE USER_GROUP.GROUP_ID=".$groupid."";
$rs = exequery( $connection, $sql );
$row = mysql_fetch_array( $rs );
$groupmember = $row['GROUP_MEMBER'];
$strgroupmember = substr( $groupmember, 0, -1 );
$strgroupmember = str_replace( ",", "','", $strgroupmember );
$strgroupmember = "'".$strgroupmember."'";
if ( $pararr['view_type'] == 0 )
{
unset( $deptnameutf8 );
unset( $action );
unset( $src );
unset( $target );
unset( $icon );
$usql = "SELECT * FROM USER WHERE USER_ID IN (".$strgroupmember.")";
$urs = exequery( $connection, $usql );
while ( $urow = mysql_fetch_array( $urs ) )
{
$userid = $urow['USER_ID'];
$useridutf8 = iconv( "GB2312", "UTF-8", $userid );
$username = $urow['USER_NAME'];
$usernameutf8 = iconv( "GB2312", "UTF-8", $username );
$pararr['userid'] = $userid;
$par = implodestpar( $pararr );
if ( $pararr['select_module'] )
{
$action = $pararr['user_url'].$userurl_fix."par=".$par;
}
else
{
$action = $pararr['user_url'].$userurl_fix."USER_ID=".$useridutf8;
}
$target = $pararr['target_frame'];
$icon = "/images/xloadtree/member.gif";
$xtreeXml->creatitem( $usernameutf8, $action, $src, $target, $icon );
}
}
$xtreeXml->endxml( );
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -