📄 prop.php
字号:
<?php
include( "../config.inc.php" );
include( "../includes/SysGlobal.php" );
include( "language/".$aLan."_".$charset.".php" );
include( "../includes/version.php" );
include( "../includes/pro.php" );
include( "func/adm.inc.php" );
include( "func/common.inc.php" );
include( "func/db.inc.php" );
include( "func/nocatch.php" );
needauth( 17 );
$step = $_REQUEST['step'];
$id = $_REQUEST['id'];
$menuid = $_REQUEST['menuid'];
$propname = $_REQUEST['propname'];
$xuhao = $_REQUEST['xuhao'];
$catid = $_REQUEST['catid'];
$pid = $_REQUEST['pid'];
echo "<html>\r\n<head >\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=";
echo $charset;
echo "\">\r\n<link id=\"style_sheet\" href=\"css/commonstyle.css\" type=\"text/css\" rel=\"stylesheet\">\r\n<title>";
echo $strAdminTitle;
echo "</title>\r\n\r\n</head>\r\n\r\n<body bgcolor=\"#d4d0c8\" >\r\n";
if ( $step == "copy" )
{
$msql->query( "delete from {$tbl_prop} where menuid='{$menuid}' and catid='{$catid}'" );
$p = 1;
$msql->query( "select * from {$tbl_prop} where menuid='{$menuid}' and catid='{$pid}'" );
while ( $msql->next_record( ) )
{
$propname = $msql->f( "propname" );
$xuhao = $msql->f( "xuhao" );
$fsql->query( "insert into {$tbl_prop} values(\r\n\t\t\t0,\r\n\t\t\t'{$menuid}',\r\n\t\t\t'{$catid}',\r\n\t\t\t'{$propname}',\r\n\t\t\t'{$xuhao}'\r\n\t\t\t)" );
$p++;
}
}
if ( $step == "add" )
{
$msql->query( "select count(id) from {$tbl_prop} where menuid='{$menuid}' and catid='{$catid}'" );
if ( $msql->next_record( ) )
{
$count = $msql->f( "count(id)" );
}
if ( $propname == "" )
{
popback( $strColPropNotice1, "prop.php?menuid={$menuid}&catid={$catid}&pid={$pid}" );
}
if ( 20 <= $count )
{
popback( $strColPropNotice2, "prop.php?menuid={$menuid}&catid={$catid}&pid={$pid}" );
}
$msql->query( "select max(xuhao) from {$tbl_prop} where menuid='{$menuid}' and catid='{$catid}' " );
if ( $msql->next_record( ) )
{
$max = $msql->f( "max(xuhao)" );
}
$max = $max + 1;
$msql->query( "insert into {$tbl_prop} values(\r\n0,\r\n'{$menuid}',\r\n'{$catid}',\r\n'{$propname}',\r\n'{$max}'\r\n)" );
}
if ( $step == "modify" )
{
$msql->query( "update {$tbl_prop} set propname='{$propname}',xuhao='{$xuhao}' where id='{$id}'" );
}
if ( $step == "del" )
{
$msql->query( "delete from {$tbl_prop} where id='{$id}'" );
}
echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\r\n <tr valign=\"top\"> \r\n <td> <fieldset><legend>";
echo $strColPropTitle;
echo "</legend> \r\n <table width=\"300\" border=\"0\" cellspacing=\"1\" cellpadding=\"0\" height=\"3\">\r\n <tr> \r\n <td></td>\r\n </tr>\r\n </table>\r\n <table width=\"92%\" border=\"0\" cellspacing=\"1\" cellpadding=\"2\" align=\"center\" height=\"30\">\r\n <tr> \r\n <form method=\"get\" action=\"prop.php\">\r\n <td height=\"48\" > \r\n \r\n <input type=\"hidden\" name=\"me";
echo "nuid\" value=\"";
echo "{$menuid}";
echo "\">\r\n <input type=\"hidden\" name=\"catid\" value=\"";
echo "{$catid}";
echo "\">\r\n\t\t\t <input type=\"hidden\" name=\"pid\" value=\"";
echo "{$pid}";
echo "\">\r\n <input type=\"hidden\" name=\"step\" value=\"add\">\r\n ";
echo $strColPropAdd;
echo " \r\n <input type=\"text\" name=\"propname\" style=\"height:20px\" size=\"20\">\r\n <input type=\"submit\" name=\"Submit\" value=\"";
echo $strAdd;
echo "\" class=button>\r\n\t\t\t ";
if ( $pid != 0 || $catid != 0 )
{
echo " <input type=\"button\" name=\"cc2\" value=\"";
echo $strColPropCopy;
echo "\" onClick=\"self.location='prop.php?step=copy&menuid=";
echo $menuid;
echo "&pid=";
echo $pid;
echo "&catid=";
echo $catid;
echo "'\" class=button>\r\n";
}
echo " \r\n </td>\r\n </form>\r\n </tr>\r\n </table>\r\n <table width=\"92%\" border=\"0\" cellspacing=\"2\" cellpadding=\"0\" align=\"center\" style=\" border:1px inset; border-color: #d4d0c8 inset\" height=\"330\" >\r\n <tr valign=\"top\"> \r\n <td> \r\n <div id=\"Layer1\" style=\"position:absolute; width:100%; height:100%; z-index:1; overflow: auto;border:0px; scrollbar-face-col";
echo "or: #E1E0DD; scrollbar-highlight-color: #ffffff; scrollbar-shadow-color: #E1E0DD; scrollbar-arrow-color: #ffffff; crollbar-base-color: #E1E0DD; scrollbar-dark-shadow-color: #E1E0DD;; visibility: visible\"> \r\n <table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"2\" align=\"center\">\r\n <tr> \r\n <td width=\"30\" align=\"center\" height=\"25\">";
echo $strNumber;
echo "</td>\r\n <td width=\"80\" align=\"center\" height=\"25\">";
echo $strXuhao;
echo "</td>\r\n <td height=\"25\" >";
echo $strColPropName;
echo "</td>\r\n <td width=\"64\" align=\"center\" height=\"25\">";
echo $strModify;
echo "</td>\r\n <td width=\"61\" align=\"center\" height=\"25\" >";
echo $strDel;
echo "</td>\r\n </tr>\r\n ";
$msql->query( "select * from {$tbl_prop} where menuid='{$menuid}' and catid='{$catid}' order by xuhao" );
$i = 1;
while ( $msql->next_record( ) )
{
$id = $msql->f( "id" );
$propname = $msql->f( "propname" );
$xuhao = $msql->f( "xuhao" );
echo " \r\n <tr> \r\n <td width=\"30\" align=\"center\">";
echo "{$i}";
echo "</td>\r\n <form method=\"get\" action=\"prop.php\">\r\n <td width=\"80\" align=\"center\"> \r\n <input type=\"text\" name=\"xuhao\" size=\"5\" value=\"";
echo "{$xuhao}";
echo "\" style=\"height:20px\" >\r\n </td>\r\n <td > \r\n <input type=\"text\" name=\"propname\" size=\"18\" value=\"";
echo "{$propname}";
echo "\" style=\"height:20px\" >\r\n <input type=\"hidden\" name=\"id\" value=\"";
echo "{$id}";
echo "\">\r\n <input type=\"hidden\" name=\"menuid\" value=\"";
echo "{$menuid}";
echo "\">\r\n\t\t\t\t\t <input type=\"hidden\" name=\"catid\" value=\"";
echo "{$catid}";
echo "\">\r\n\t\t\t\t\t <input type=\"hidden\" name=\"pid\" value=\"";
echo "{$pid}";
echo "\">\r\n <input type=\"hidden\" name=\"step\" value=\"modify\">\r\n </td>\r\n <td width=\"64\" > \r\n <div align=\"CENTER\"> \r\n <input type=\"submit\" name=\"cc\" value=\"";
echo $strModify;
echo "\" class=button>\r\n </div>\r\n </td>\r\n <td width=\"61\" align=\"center\" > \r\n <input type=\"button\" name=\"cc\" value=\"";
echo $strDelete;
echo "\" onClick=\"self.location='prop.php?step=del&menuid=";
echo $menuid;
echo "&pid=";
echo $pid;
echo "&catid=";
echo $catid;
echo "&id=";
echo $id;
echo "'\" class=button>\r\n </td>\r\n </form>\r\n </tr>\r\n ";
$i++;
}
echo " \r\n </table>\r\n </div>\r\n </td>\r\n </tr>\r\n </table>\r\n <table width=\"100%\" border=\"0\" cellspacing=\"2\" cellpadding=\"0\" align=\"center\">\r\n <tr align=\"center\"> \r\n <td height=\"36\">\r\n \r\n <input type=\"button\" name=\"Button2\" value=\"";
echo $strWindowClose;
echo "\" class=button onClick=\"window.close();\">\r\n</td>\r\n </tr>\r\n </table>\r\n </fieldset></td>\r\n </tr>\r\n</table>\r\n\r\n</body>\r\n</html>\r\n";
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -