📄 modify.php
字号:
<?
//**************************************************
//************************************
//******Powered by ajin ***************
//*****联系我:wenjinjin@peoplemail.com.cn *******
//*********QQ : 89243743 ********************
//*******主页: http://www.52686.com *******
//**************************************************
include ('session.php');
include_once('function.php');
include_once('config.php');
if (islogin($_SESSION['username'],$_SESSION['userpass']))
$accept=true;
else {
$accept=false;
echo "<meta http-equiv=\"refresh\" content=\"0;URL=index.php\">";
exit;
}
?>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>修改</title>
<link href="css.css" rel="stylesheet" type="text/css">
</head>
<body bgcolor="#F3F7FC" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<?
include('config.php');
include('classgroup.php');
$worker_login_name=$_SESSION['username'];
$addname=$_POST['addname'];
$addarea=$_POST['addarea'];
$addmod=$_POST['addmod'];
$modifymod=$_GET['modifymod'];
$show=new database($dbname);
mysql_select_db($dbname);
$time_num=$_GET['time_num'];
if ($modifymod=="text")
{ $showflag=true;
$name_value=$show->get_term("worker_text_name","work_text","where worker_text_time=".$_GET['time_num']." and worker_login_name='".$worker_login_name."'");
$area_value=$show->get_term("worker_text","work_text","where worker_text_time=".$_GET['time_num']." and worker_login_name='".$worker_login_name."'");
if ($_POST['addmod']&&$addname==""&&$accept)
{
$errormeg="<font color=red >错误 </font>: 无标题么?";
}
elseif($_POST['addmod']&&$addarea==""&$accept)
{
$errormeg="<font color=red>错误 </font> : 文档怎么没有内容?";
}
elseif ($_POST['addmod']&&$accept&&$addname!=""&&$addarea!="")
{
if ($_POST['share']=="someshare") $text_mod="局部共享";
elseif ($_POST['share']="allshare") $text_mod="无限制共享";
else $text_mod="没有共享";
$query="update work_text set worker_text_name='".$_POST['addname']."',worker_text='".$_POST['addarea']."',worker_text_mod='".$text_mod."' where worker_text_time=".$_GET['time_num'];
if (mysql_query($query))
{
$showflag=false;
$errormeg="成功";
}
}
}
elseif ($modifymod=="note")
{ $showflag=true;
$name_value=$show->get_term("note_name","notbook","where note_time=".$_GET['time_num']." and worker_login_name='".$worker_login_name."'");
$area_value=$show->get_term("note_text","notbook","where note_time=".$_GET['time_num']." and worker_login_name='".$worker_login_name."'");
if ($_POST['addmod']&&$addname==""&&$accept)
{
$errormeg="<font color=red >错误 </font>: 无标题么?";
}
elseif($_POST['addmod']&&$addarea==""&$accept)
{
$errormeg="<font color=red>错误 </font> : 内容?";
}
elseif ($_POST['addmod']&&$accept&&$addname!=""&&$addarea!="")
{
$query="update notbook set note_name='".$_POST['addname']."',note_text='".$_POST['addarea']."' where note_time=".$_GET['time_num']." and worker_login_name='$worker_login_name'";
if (mysql_query($query))
{
$showflag=false;
$errormeg="成功";
}
}
}
elseif ($modifymod=="meninfo"&&$accept)
{
$showflag=true;
if($_POST['addmod']&&$_POST['worker_name']!=""&&$_POST['worker_email']!="")
{
$query="update worker set worker_name='".$_POST['worker_name']."',worker_email='".$_POST['worker_email'].
"',classphone='".$_POST['class_phone']."',homephone='".$_POST['homephone']."',handphone='".$_POST['handphone']."',home_add='".$_POST['home_add']."',other_conn='".$_POST['other_conn'].
"' where login_name='$worker_login_name'";
if (mysql_query($query))
$showflag=false;
}
}
if ($showflag&&$modifymod=="text"&&$accept)
{
require('template/form.php');
}
elseif($showflag&&$modifymod=="note"&&$accept)
{
require('template/noteform.php');
}
elseif($showflag&&$modifymod=="meninfo"&&$accept)
{
$show->loadtemp($_GET[mod],$count,$lim,"worker_name,worker_mod,worker_job,worker_email,classphone,handphone,homephone,home_add,other_conn ","worker",8,"template/menform.php","template/menform_so.php","where login_name='".$_SESSION['username']."'");
}
elseif (!$showflag) require('template/suss.php');
?>
<table width="90%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td> </td>
</tr>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -