⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 edit.php

📁 极限网络智能办公系统—MYOA26—100%—源程序。
💻 PHP
字号:
<?php

include_once( "inc/auth.php" );
echo "\r\n<html>\r\n<head>\r\n<title>表新建或编辑</title>\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=gb2312\">\r\n\r\n";
echo "<S";
echo "CRIPT language=javascript>\r\nfunction check_form()\r\n{\r\n  if(document.form1.TABLE_NAME.value == \"\")\r\n  {\r\n     alert(\"表名不能为空!\");\r\n     return false;\r\n  }\r\n  if(document.form1.TABLE_DESC.value == \"\")\r\n  {\r\n     alert(\"表描述不能为空!\");\r\n     return false;\r\n  }\r\n  \r\n  return true;\t\r\n}\r\n</SCRIPT>\r\n</head>\r\n\r\n<body class=\"bodycolor\" topmargin=\"5\" onload=\"document.form1.TABLE_NAME.focus();\">\r\n\r\n";
if ( $TABLE_ID != "" )
{
	$TITLE = "编辑表";
}
else
{
	$TITLE = "新建表";
}
echo "\r\n<table border=\"0\" width=\"100%\" cellspacing=\"0\" cellpadding=\"3\" class=\"small\">\r\n  <tr>\r\n    <td class=\"Big\"><img src=\"/images/edit.gif\" WIDTH=\"22\" HEIGHT=\"20\" align=\"absmiddle\">";
echo "<s";
echo "pan class=\"big3\"> ";
echo $TITLE;
echo "</span><br>\r\n    </td>\r\n  </tr>\r\n</table>\r\n\r\n";
$connection = openconnection( );
if ( $TABLE_ID != "" )
{
	$query = "SELECT * from IK_TABLE where TABLE_ID={$TABLE_ID}";
	$cursor = exequery( $connection, $query );
	if ( $ROW = mysql_fetch_array( $cursor ) )
	{
		$TABLE_NAME = $ROW['TABLE_NAME'];
		$TABLE_DESC = $ROW['TABLE_DESC'];
	}
}
echo "\r\n<hr width=\"95%\" height=\"1\" align=\"left\" class=\"big1\">\r\n\r\n<table border=\"0\" width=\"450\" cellpadding=\"2\" cellspacing=\"1\" align=\"center\" bgcolor=\"#000000\" class=\"small\">\r\n  <form action=\"";
if ( $TABLE_ID != "" )
{
	echo "update";
}
else
{
	echo "insert";
}
echo ".php\" method=\"post\" name=\"form1\" onSubmit=\"return check_form();\">\r\n    <tr> \r\n      <td nowrap class=\"TableData\">表名:</td>\r\n      <td class=\"TableData\"> \r\n        <input type=\"text\" name=\"TABLE_NAME\" size=\"30\" maxlength=\"100\" class=\"BigInput\" value=\"";
echo $TABLE_NAME;
echo "\">\r\n      </td>\r\n    </tr>\r\n    <tr> \r\n      <td nowrap class=\"TableData\">表描述:</td>\r\n      <td class=\"TableData\"> \r\n        <input type=\"text\" name=\"TABLE_DESC\" size=\"30\" maxlength=\"100\" class=\"BigInput\" value=\"";
echo $TABLE_DESC;
echo "\">\r\n      </td>\r\n    </tr>\r\n    <tr align=\"center\" class=\"TableControl\"> \r\n      <td colspan=\"2\" nowrap>\r\n        <input type='hidden' value=\"";
echo $TABLE_ID;
echo "\" name=\"TABLE_ID\">\r\n        <input type=\"submit\"  value=\"保存\" class=\"BigButton\" name=\"submit\">&nbsp;&nbsp; \r\n        <input type=\"button\"  value=\"返回\" class=\"BigButton\" name=\"back\" onClick=\"history.back();\">\r\n      </td>\r\n    </tr>\r\n  </form>\r\n</table>\r\n</body>\r\n</html>";
?>

⌨️ 快捷键说明

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