📄 index.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";
echo "<s";
echo "cript language=\"javascript\" src=\"/fck/fckeditor.js\"></script>\r\n";
echo "<s";
echo "cript language=\"javascript\" src=\"/fck/added.js\" ></script>\r\n";
echo "<s";
echo "cript language=\"javascript\" src=\"/inc/common.js\" ></script>\r\n";
echo "<S";
echo "CRIPT language=javascript src=\"/inc/calendar/calendar.js\"></SCRIPT>\r\n";
echo "<s";
echo "cript Language=\"JavaScript\">\r\nfunction CheckForm()\r\n{\r\n\tif(document.form1.TO_ID.value==\"\")\r\n\t{\r\n\t\talert(\"请指定发布范围!\");\r\n\t\treturn (false);\r\n\t}\r\n\tif(document.form1.SUBJECT.value==\"\")\r\n\t{\r\n\t\talert(\"公告通知的标题不能为空!\");\r\n\t\treturn (false);\r\n\t}\r\n\toEditor = FCKeditorAPI.GetInstance(\"fckeditor1\");\r\n\tContent = oEditor.GetXHTML();\r\n\tif(Content==\"\")\r\n\t{\r\n\t\talert(\"公告通知的内容不能为空!\");\r\n\t\tr";
echo "eturn (false);\r\n\t}\r\n\tif (document.form1.ATTACHMENT.value!=\"\")\r\n\t{\r\n\t\tvar file_temp=document.form1.ATTACHMENT.value,file_name;\r\n\t\tvar Pos;\r\n\t\tPos=file_temp.lastIndexOf(\"\\\\\");\r\n\t\tfile_name=file_temp.substring(Pos+1,file_temp.length);\r\n\t\tdocument.form1.ATTACHMENT_NAME.value=file_name;\r\n\t}\r\n\tdocument.form1.OP.value=\"1\";\r\n\treturn (true);\r\n}\r\n\r\nfunction sendForm()\r\n{\r\n\tif(CheckForm())\r\n\t\tdocument.form1.";
echo "submit();\r\n}\r\n\r\nfunction clear_dept()\r\n{\r\n\tdocument.form1.TO_NAME.value=\"\";\r\n\tdocument.form1.TO_ID.value=\"\";\r\n}\r\nfunction Load_Do()\r\n{\r\n\t//EDIT_HTML.insertHtml(document.form1.CONTENT.value);\r\n}\r\n\r\nfunction td_calendar(fieldname)\r\n{\r\n\tmyleft=document.body.scrollLeft+event.clientX-event.offsetX-80;\r\n\tmytop=document.body.scrollTop+event.clientY-event.offsetY+140;\r\n\twindow.showModalDialog(\"/inc/calend";
echo "ar.php?FIELDNAME=\"+fieldname,self,\"edge:raised;scroll:0;status:0;help:0;resizable:1;dialogWidth:280px;dialogHeight:205px;dialogTop:\"+mytop+\"px;dialogLeft:\"+myleft+\"px\");\r\n}\r\n\r\nfunction upload_attach()\r\n{ \r\n\t// document.form1.CONTENT.value=EDIT_HTML.get_docHtml();\r\n\tif(CheckForm())\r\n\t{\r\n\t\tdocument.form1.OP.value=\"0\";\r\n\t\tdocument.form1.submit();\r\n\t}\r\n}\r\n\r\nfunction delete_attach(ATTACHMENT_ID,ATTACH";
echo "MENT_NAME)\r\n{\r\n\tmsg=\"确定要删除文件 '\"+ ATTACHMENT_NAME +\"' 吗?\";\r\n\tif(window.confirm(msg))\r\n\t{\r\n\t\tURL=\"../delete_attach.php?NOTIFY_ID=";
echo $NOTIFY_ID;
echo "&ATTACHMENT_ID=\"+ATTACHMENT_ID+\"&ATTACHMENT_NAME=\"+ATTACHMENT_NAME;\r\n\t\twindow.location=URL;\r\n\t}\r\n}\r\n</script>\r\n</head>\r\n\r\n<body class=\"bodycolor\" topmargin=\"5\" onLoad=\"Load_Do();\">\r\n<form enctype=\"multipart/form-data\" action=\"submit.php\" method=\"post\" name=\"form1\" >\r\n<table border=\"0\" width=\"100%\" cellspacing=\"1\" cellpadding=\"0\" class=\"small\">\r\n <tr>\r\n <td class=\"tablehead1\"><img src=\"/images/manage/";
echo "news.gif\" align=\"absmiddle\"> 新建公告通知\r\n </td>\r\n </tr>\r\n <tr class=\"tablehead2\">\r\n <td>\r\n <a href=\"#\" onClick=\"sendForm();\"><img src=\"/images/button/issue.gif\" border=\"0\" title=\"发布\"></a>\r\n <a href=\"#\" onClick=\"location='index.php?USER_ID=";
echo $USER_ID;
echo "&DEPT_ID=";
echo $DEPT_ID;
echo "'\"><img src=\"/images/button/reset.gif\" border=\"0\"></a>\r\n <a href=\"#\" onClick=\"location='../'\"><img src=\"/images/button/return.gif\" border=\"0\"></a>\r\n </td>\r\n </tr>\r\n</table>\r\n<br>\r\n<table border=\"0\" width=\"100%\" cellpadding=\"2\" cellspacing=\"1\" class=\"small\">\r\n <tr>\r\n <td nowrap class=\"TableLine2\" width=\"10%\">发布范围(部门):</td>\r\n <td class=\"TableLine1\">\r\n <input type=\"hidden\" name=\"TO_ID\" val";
echo "ue=\"";
echo $TO_ID;
echo "\">\r\n <textarea cols=30 name=\"TO_NAME\" rows=2 class=\"BigStatic\" wrap=\"yes\" readonly>";
echo $TO_NAME;
echo "</textarea>\r\n <input type=\"button\" value=\"添 加\" class=\"SmallButton\" onClick=\"LoadWindowDeptAll('TO_ID','TO_NAME','form1')\" title=\"添加部门\" name=\"button\">\r\n <input type=\"button\" value=\"清 空\" class=\"SmallButton\" onClick=\"clear_dept()\" title=\"清空部门\" name=\"button\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableLine2\"> 标题:</td>\r\n <td class=\"TableLine1\">\r";
echo "\n <input type=\"text\" name=\"SUBJECT\" size=\"40\" maxlength=\"40\" class=\"BigInput\" value=\"";
echo $SUBJECT;
echo "\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableLine2\"> 有效期:</td>\r\n <td class=\"TableLine1\">\r\n 生效日期:\r\n\t\t<input class='Wdate' type=\"text\" name=\"BEGIN_DATE\" id=\"BEGIN_DATE\" value=\"";
echo $BEGIN_DATE;
echo "\" size=\"12\" maxlength=\"10\" onclick=\"popUpCalendar(document.form1,document.form1.BEGIN_DATE,'yyyy-mm-dd')\"/>\r\n 为空为立即生效<br>\r\n 终止日期:\r\n\t\t<input class='Wdate' type=\"text\" name=\"END_DATE\" id=\"END_DATE\" value=\"";
echo $END_DATE;
echo "\" size=\"12\" maxlength=\"10\" onclick=\"popUpCalendar(document.form1,document.form1.END_DATE,'yyyy-mm-dd')\"/>\r\n 为空为立即生效<br></td>\r\n </tr>\r\n \t<tr>\r\n <td nowrap class=\"TableLine2\">附件:</td>\r\n <td class=\"TableLine1\">\r\n <input type=\"file\" name=\"ATTACHMENT\" size=\"30\" class=\"BigInput\" title=\"选择附件文件\">\r\n <input type=\"button\" class=\"BigButton\" value=\"上传附件\" onClick=\"";
echo "upload_attach();\">\r\n <input type=\"hidden\" name=\"ATTACHMENT_ID_OLD\" value=\"";
echo $ATTACHMENT_ID;
echo "\">\r\n <input type=\"hidden\" name=\"ATTACHMENT_NAME_OLD\" value=\"";
echo $ATTACHMENT_NAME;
echo "\">\r\n </td>\r\n </tr>\r\n <tr>\r\n <td nowrap class=\"TableLine2\"> 提醒:</td>\r\n <td class=\"TableLine1\">\r\n <input type=\"checkbox\" name=\"SMS_REMIND\" checked>使用短信息提醒员工\r\n </td>\r\n </tr>\r\n <tr>\r\n\t\t<td class=\"TableLine2\" colspan=\"2\">\r\n <textarea id=\"fckeditor1\" name=\"fckeditor1\" >";
echo $fckeditor1;
echo "</textarea>\r\n </td>\r\n </tr>\r\n <input type=\"hidden\" name=\"ATTACHMENT_NAME\" value=\"\">\r\n <input type=\"hidden\" name=\"OP\" value=\"\">\r\n</table>\r\n";
echo "<s";
echo "cript type=\"text/javascript\">\r\n\tcreatepicdiv();\r\n\tvar oFCKeditor = new FCKeditor('fckeditor1');\r\n\toFCKeditor.BasePath = \"/fck/\" ;\r\n\toFCKeditor.Width = '100%' ;\r\n\toFCKeditor.Height = '400' ;\r\n\toFCKeditor.ToolbarSet = 'Eoffice' ;\r\n\toFCKeditor.ReplaceTextarea() ;\r\n</script>\r\n</form>\r\n</body>\r\n</html>\r\n";
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -