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

📄 add_article.asp

📁 if you want it,call me.
💻 ASP
字号:
<!--#include file="conn.asp"-->
<!--#include file="UBBencode.ini"-->
<!--#include file="textencode.ini"-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>发表博文</title>
<style type="text/css">
body{
margin:0px;
background-color:#FF9900;
}
#all{
width:780px;
margin-right:auto;
padding-left:10px;
}
form{
margin:0px;}
#title{
	color:orange;
	width:780px;
	height:25px;
	background-color:#FFFFFF;
	text-align:center;
	font-weight:bolder;
	padding-top:5px;
	font-size:24px;
	border: 1px dotted #CCCCCC;
}
#title_top{
	width:780px;
	height:30px;
	background-color:#FFFFFF;
	text-align:center;
	font-weight:bolder;
	padding-top:10px;
	border: 1px none #333333;
	color:orange;
}
#tools{
	width:780px;
	height:auto;
	background-color:#CCCCCC;
	text-align:center;
	font-weight:bolder;
	border: 1px none #999999;
	padding-top:5px;
	padding-bottom:5px;
	FILTER:progid:DXImageTransform.Microsoft.Gradient(startColorStr='#ffffff', endColorStr='orange', gradientType='1'); 
}
#bottom{
	width:780px;
	height:auto;
	background-color:#ffffff;
	text-align:center;
	border: 1px none #999999;
	padding-top:8px;
	padding-bottom:8px;
}
.btn{
	background-color:#FFFFFF;
	border: 1px solid #CCCCCC;
}
</style>
<script language="JAVASCRIPT">
	var editMode=true;	
function loadForm()
{
  editor.HtmlEdit.document.body.innerHTML=document.myform.body.value;
  return true
}
</script>
<script language = "JavaScript">
function CheckForm()
{
  if (editor.EditMode.checked==true)
	  document.myform.Content.value=editor.HtmlEdit.document.body.innerText;
  else
	  document.myform.Content.value=editor.HtmlEdit.document.body.innerHTML; 

  if (document.myform.Title.value=="")
  {
    alert("文章标题不能为空!");
	document.myform.Title.focus();
	return false;
  }
  if (document.myform.classname.value=="num")
  {
    alert("请选择文章分类!");
	document.myform.classname.focus();
	return false;
  }
  if (document.myform.Content.value=="")
  {
    alert("文章内容不能为空!");
	editor.HtmlEdit.focus();
	return false;
  }
  return true;  
}
function loadForm()
{
  editor.HtmlEdit.document.body.innerHTML=document.myform.Content.value;
  return true
}
</script>
	
</head>
<body >
<%
if session("msmax")="" then
	response.Redirect("login.asp")
end if
%>
	<div id="all">
	 <form method="POST" name="myform" onSubmit="return CheckForm();" action="save_article.asp" target="_self">
		<div id="title">发表博文</div>
		<div id="title_top">		 
		   博文标题:
		      <input name="Title" type="text" class="btn" size="50" />	     
	    </div>
		<div id="title_top">		 
		   文章分类:
		     <select name="classname">
				<option value="num">请选择文章分类</option>
			 <%
					dim classRs,classSql
					set classRs=server.createobject("adodb.recordset")
					classSql="select * from class order by classid desc"
					classRs.open classSql,db,1
					do while not classRs.eof
				%>
		       <option value="<%=classRs("classid")%>"><%=classRs("classname")%></option>
			   <%
			   classRs.movenext
			   loop
			   %>
             </select>
</div>	  
	<div id="tools">	
		<!--<input name="media" type="button" class="btn" onClick="insert('[MP=480,360]http://[/MP]')" value="Media">
		&nbsp;
	 	<input name="real" type="button" class="btn" onClick="insert('[RM=480,360]http://[/RM]')" value="Real">-->
					<div align="left"> 
                      <textarea name="Content" style="display:none"></textarea>
                      <iframe ID="editor" src="editor.asp" frameborder=1 scrolling=no width="100%" height="600"></iframe>
                    </div>		
			</div>		
		<div id="bottom">
		  <input name="Submit" type="Submit" class="btn" value="发表博文" />
		</div> 
	</form
	></div>
</body>
</html>

⌨️ 快捷键说明

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