?? add.asp
字號:
<%
if session("admin_name")="" then
response.redirect "index.asp"
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<script LANGUAGE="JavaScript">
function check()
{
if (document.form1.title.value=="")
{
alert("請輸入新聞標(biāo)題!")
document.form1.title.focus()
document.form1.title.select()
return
}
document.form1.submit()
}
</script>
</head>
<!--#include file="../inc/adconn.asp"-->
<link rel="stylesheet" type="text/css" href="../style.css">
<body bgcolor="#FFFFFF" marginheight=0 marginwidth=0 leftmargin=5>
<SCRIPT language=javascript>
var upfile_obj;
function OnUpFile()
{
upfile_obj.src=upfile_obj.lowsrc;
upfile_obj.src=document.forms["form1"].upfile.value;
}
</SCRIPT>
<CENTER><form name="form1" method="post" action="savenews.asp">
<INPUT name=upfile onchange=return(OnUpFile()) type=hidden>
<TABLE width="100%" border="0" cellpadding="4" cellspacing="1" bgcolor="#336699">
<TR>
<TD height=30 colspan=2 background="../images/pics/tile_sub.gif" bgcolor="#e8f4ff"><b>添加新聞</b></TD>
</TR>
<TR bgcolor="#FFFFFF">
<TD width="17%">新聞標(biāo)題:</TD>
<TD width="83%">
<input type="text" name="title" size="52"><font color=#ff6600> *</font></TD>
</TR>
<TR bgcolor="#FFFFFF">
<TD>新聞分類:</td>
<TD>
<select name="typeid">
<%dim rs,sql,sel,typeid
typeid=request("typeid")
set rs=server.createobject("adodb.recordset")
sql="select * from newstype"
rs.open sql,conn,1,1
do while not rs.eof
if typeid=cstr(rs("typeid")) then
sel="selected"
else
sel=""
end if
response.write "<option " & sel & " value='"+CStr(rs("typeID"))+"' name=typeid>"+rs("type")+"</option>"+chr(13)+chr(10)
rs.movenext
loop
rs.close
%>
</select><%'=typeid%>
</TD>
</TR>
<TR bgcolor="#FFFFFF">
<TD>推薦新聞:</td>
<TD>
<INPUT name=tj type=radio value="1">推薦 <INPUT name=tj type=radio value="0" CHECKED>不推薦</TD>
</TR>
<TR bgcolor="#FFFFFF">
<TD>新聞內(nèi)容:</TD>
<TD><input type="hidden" name="content" value=""> <IFRAME ID="eWebEditor1" SRC="../eWebEditor/ewebeditor.asp?id=content&style=standard_coolblue" FRAMEBORDER="0" SCROLLING="no" WIDTH="550" HEIGHT="350"></IFRAME><font color=#ff6600> *</font></TD>
</TR>
<TR bgcolor="#FFFFFF">
<TD>來源:</TD>
<TD>
<input type="text" name="nfrom" size="30"></TD>
</TR>
<TR bgcolor="#FFFFFF">
<TD>是否包含圖片:</td>
<TD>
<INPUT name=ispic type=radio value="1">
包含 <INPUT name=ispic type=radio value="0" CHECKED>不包含</TD>
</TR>
<TR bgcolor="#FFFFFF">
<TD> 上傳文件: </TD>
<TD>
<iframe name="ad" frameborder=0 width=100% height=50 scrolling=no src=upload.asp></iframe></TD>
</TR>
<TR height="30">
<TD colspan="2" align="center" background="../images/pics/tile_sub.gif" bgcolor="#e8f4ff" >
<input type="button" value=" 提 交" onclick="check()">
<input type="button" name="Submit2" value=" 重 執(zhí)">
</TR>
</TABLE>
</FORM>
</BODY>
</HTML>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -