|
Server : Apache/2.2.2 (Fedora) System : Linux App1.pathumtani.go.th 2.6.20-1.2320.fc5smp #1 SMP Tue Jun 12 19:40:16 EDT 2007 i686 User : apache ( 48) PHP Version : 5.2.9 Disable Function : NONE Directory : /var/www/html/eoffice/application/document/ |
Upload File : |
<?
session_start();
$nochecklogin= true;
include("../../config/config.inc.php");
function Query1($sql){
$result = mysql_query($sql);
echo mysql_error();
$rs = mysql_fetch_array($result);
return $rs[0];
}
if($_GET[select_group]){
$g_check=$_GET['select_group'];
if($session_gid[$session_staffid][$g_check]){
unset($_SESSION[session_gid] );
session_register("session_gid");
foreach($session_gid as $vid => $val){
foreach($val as $v1 => $v2){
$gid_checks=$v2;
if($gid_checks==$g_check){
$session_gid[$session_staffid][$g_check]=$g_check;
}else{
unset($session_gid[$session_staffid][$g_check]);
}
}
}
// $session_gid[$session_staffid][$g_check]=$g_check;
header("Location: docreg.php");
exit;
}else{
echo "<meta http-equiv='refresh' content='1;url=logout.php'>" ;
}
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
<html>
<head>
<title>ระบบทะเบียนหนังสือ</title>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874">
<LINK href="../../common/style.css" rel=stylesheet>
<style type="text/css">
<!--
.header1 { font-family:"MS Sans Serif", Tahoma, Arial;
font-size:1em;
font-weight:bold;
color: #FFFFFF;
}
.main { font-family:"MS Sans Serif", Tahoma, Arial;
font-size:0.8em;
color:#FF0000;
font-weight:bold;
}
.normal { font-family:"MS Sans Serif", Tahoma, Arial;
font-size:0.8em;
}
body {
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
}
-->
</style>
</head>
<body style="filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0, StartColorStr='#273F6F', EndColorStr='#ffffff');">
<table width="100%" height="600" border="0" cellpadding="0" cellspacing="0">
<tr>
<td align="center"><table width="690" height="405" border="0" cellpadding="5" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td align="center" valign="middle" style="border:#818181 solid 1px; ">เนื่องจากมีสิทธิ์ในการเข้าถึงระบบมากกว่า 1 <BR>
ขอให้ท่านเลือก เข้าใช้งานในสิทธิ์เพียงกลุ่มใดกลุ่มหนึ่งตามรายการด้านล่างนี้<BR><br>
<?
// print_r($session_gid);
$code_seect="";
foreach($session_gid as $vid => $val){ $r=0;
foreach($val as $v1 => $v2){
if($r=="0"){ $code_seect.=" AND ( "; }else{ $code_seect.=" or "; }$r++;
$code_seect.=" gid = '$v2' ";
}
$code_seect.=" ) ";
}
$sql_group="
select * from $table_staffgroup where org_id=2
$code_seect
";
$result=mysql_query($sql_group);
while($rslist=mysql_fetch_assoc($result)){
?><li><b><a href="?select_group=<?=$rslist[gid]?>"><?=$rslist[groupname]?></a></b><br><?
}
?>
</td>
</tr>
</table>
<br>
</td>
</tr>
</table>
</body>
</html>