left.php

来自「帝国CMS,功能全面的CMS源码,下载试用下」· PHP 代码 · 共 1,021 行 · 第 1/3 页

PHP
1,021
字号
<?php
require("../../../class/connect.php");
include("../../../class/db_sql.php");
include("../../../class/config.php");
include("../../../class/functions.php");
$link=db_connect();
$empire=new mysqlquery();
$logininid=getcvar('loginuserid');
$loginin=getcvar('loginusername');
$loginrnd=getcvar('loginrnd');
$loginlevel=getcvar('loginlevel');
is_login($logininid,$loginin,$loginrnd);
$r=ReturnLeftLevel($loginlevel);
$movecolor=" onMouseOver=\"this.style.backgroundColor='#EFEFEF'\" onMouseOut=\"this.style.backgroundColor='#FFFFFF'\"";
//模型
$msql=$empire->query("select mid,mname from {$dbtbpre}enewsmod order by mid");
while($mr=$empire->fetch($msql))
{
	$m.="<tr> 
      <td height='25' bgcolor='#FFFFFF'".$movecolor.">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href='../../[!--link--]?mid=".$mr[mid]."' target='main'>".$mr[mname]."</a></td>
    </tr>";
}
$mcheck=str_replace("[!--link--]","CheckNews.php",$m);
$mqf=str_replace("[!--link--]","ListNewsQf.php",$m);
db_close();
$empire=null;
//风格
$loginadminstyleid=(int)getcvar('loginadminstyleid');
//参数设置
$display="";
if($display=="")
{
$addimg="images/noadd.gif";
}
else
{
$addimg="images/add.gif";
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>菜单</title>
<link rel="stylesheet" href="adminstyle.css" type="text/css">
<SCRIPT lanuage="JScript">
if(self==top)
{self.location.href='../../admin.php';}
var theall="sysimg|classimg|picinfoimg|fileimg|checkimg|qfimg|userimg|memberimg|doimg|cardimg|toolimg|modimg|modfunimg|bakimg";
//保存
function SaveSeting()
{
	var i,str="";
	r=theall.split("|");
	for(i=0;i<r.length;i++)
	{
		if(DisplayImg("",r[i],3)==1)
		{
			str+=r[i]+"|";
		}
	}
	if(str!="")
	{
		str="<!!---|"+str+"---!!>";
	}
	SetMyCookie(str);
}
//设置cookie
function SetMyCookie(str)
{
	var expdate=new Date();
	expdate.setTime(expdate.getTime()+(24*60*60*1000*365));
	expirestr=";expires="+expdate.toGMTString();
	var mycookie=str+expirestr;
	document.cookie=mycookie;
}
//全部展开
function DisplayAll(phome)
{
	var i,cstr,str="";
	r=theall.split("|");
	//cookie
	if(phome==3)
	{
		cstr=document.cookie;
		if(cstr!="")
		{
		cr=cstr.split("<!!---");
			if(cr[0]!=cstr)
			{
				crr=cr[1].split("---!!>");
				str=crr[0];
			}
		}
	}
	for(i=0;i<r.length;i++)
	{
		//保存参数
		if(phome==3)
		{
			if(!(str.indexOf("|"+r[i]+"|")==-1))
			{
				DisplayImg("",r[i],1);
			}
			else
			{
				DisplayImg("",r[i],0);
			}
		}
		else
		{
			DisplayImg("",r[i],phome);
		}
	}
}
function DisplayImg(ss,imgname,phome)
{
	if(imgname=="classimg")
	{
		img=todisplay(doclass,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.classimg.src=img;
	}
	else if(imgname=="sysimg")
	{
		img=todisplay(dosys,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.sysimg.src=img;
	}
	else if(imgname=="picinfoimg")
	{
		img=todisplay(dopicinfo,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.picinfoimg.src=img;
	}
	else if(imgname=="checkimg")
	{
		img=todisplay(docheck,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.checkimg.src=img;
	}
	else if(imgname=="qfimg")
	{
		img=todisplay(doqf,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.qfimg.src=img;
	}
	else if(imgname=="fileimg")
	{
		img=todisplay(dofile,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.fileimg.src=img;
	}
	else if(imgname=="tempimg")
	{
		img=todisplay(dotemp,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.tempimg.src=img;
	}
	else if(imgname=="pubtempimg")
	{
		img=todisplay(dopubtemp,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.pubtempimg.src=img;
	}
	else if(imgname=="userimg")
	{
		img=todisplay(douser,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.userimg.src=img;
	}
	else if(imgname=="memberimg")
	{
		img=todisplay(domember,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.memberimg.src=img;
	}
	else if(imgname=="cardimg")
	{
		img=todisplay(docard,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.cardimg.src=img;
	}
	else if(imgname=="toolimg")
	{
		img=todisplay(dotool,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.toolimg.src=img;
	}
	else if(imgname=="modfunimg")
	{
		img=todisplay(domodfun,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.modfunimg.src=img;
	}
	else if(imgname=="modimg")
	{
		img=todisplay(domod,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.modimg.src=img;
	}
	else if(imgname=="doimg")
	{
		img=todisplay(dodo,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.doimg.src=img;
	}
	else if(imgname=="bakimg")
	{
		img=todisplay(dobak,phome);
		if(phome==3)
		{
			return img;
		}
		document.images.bakimg.src=img;
	}
	else
	{
	}
}
function todisplay(ss,phome)
{
var theimg;
 //全部展开
 if(phome==1)
 {
 	ss.style.display="";
	theimg="images/noadd.gif";
	return theimg;
 }
 //全部折叠
 else if(phome==2)
 {
 	ss.style.display="none";
	theimg="images/add.gif";
	return theimg;
 }
 //cookie
 else if(phome==3)
 {
  if(ss.style.display=="")
  {
  	return 1;
  }
  else
  {
  	return 0;
  }	
 }
 if(ss.style.display=="") 
 {
  	ss.style.display="none";
	theimg="images/add.gif";
  }
 else
 {
  	ss.style.display="";
	theimg="images/noadd.gif";
  }
  return theimg;
}
function turnit(ss,img)
{
 DisplayImg(ss,img,0);
}
var newWindow = null
</SCRIPT>
</head>

<body>
<table width="100%" border="0" cellspacing="1" cellpadding="3">
  <tr> 
    <td><div align="center"><a href="#ecms" onclick="DisplayAll(1);">展开</a> | <a href="#ecms" onclick="DisplayAll(2);">折叠</a> | 
        <a href="#ecms"></a><a href="#ecms" onclick="SaveSeting();">保存设置</a></div></td>
  </tr>
</table>
<br>
<table width="100%" border="0" align="center" cellpadding="4" cellspacing="1" class="tableborder">
  <tr>
    <td height="25" class="header"><img src="images/noadd.gif" width="20" height="9"><a href="../../main.php" target="main">系统首页</a></td>
  </tr>
</table>
<br>
<?
if($r[dopublic]||$r[dopostdata]||$r[dochangedata]||$r[dopl]||$r[dosearchkey]||$r[dototaldata]||$r[dorepnewstext]||$r[dodelinfodata])
{
?>
<table width="100%" border="0" align="center" cellpadding="4" cellspacing="1" class="tableborder" id="dosysid">
  <tr> 
    <td height="25" class="header"><img src="<?=$addimg?>" width="20" height="9" name="sysimg"><a href="#ecms" onMouseUp=turnit(dosys,"sysimg"); style="CURSOR: hand">系统设置</a></td>
  </tr>
  <tbody id="dosys"<?=$display?>>
  	<?
  	//参数设置
	if($r[dopublic])
	{

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?