📄 ad_edita.asp
字号:
<!--#include file="conn.asp"-->
<!--#include file="ad_chk.asp"-->
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href=inc/css.css rel=STYLESHEET type=text/css>
<%
if request("action")="edit" then
set rs=server.createobject("adodb.recordset")
sql="select * from venshop_article where id="&request("a_id")
rs.open sql,conn,1,3
rs("a_name")=request("a_name")
rs("a_author")=request("a_author")
rs("a_from")=request("a_from")
rs("a_content")=request("a_content")
asort=split(request("a_sort"),"/")
rs("a_sort")=trim(asort(0))
rs("a_nsort")=trim(asort(1))
rs("a_date")=date()
rs.update
rs.close
set rs=nothing
response.write "修改完成!"
response.write "<br>"
response.write "<a href=# onClick=history.go(-1)><font color=#ff0000>返回</font></a>"
response.end
else
set rs=server.createobject("adodb.recordset")
sql="select * from venshop_article where id="&request("a_id")
rs.open sql,conn,1,1%>
<table border="0" width="100%" style="border-collapse: collapse" cellpadding="5" bgcolor="#F0F0F0"><form name="form" method="post" action="ad_edita.asp?action=edit&a_id=<%=rs("id")%>">
<tr><td height="15">新闻标题:<input type="text" name="a_name" size="20" class=input value="<%=rs("a_name")%>">
选择分类:<select size="1" name="a_sort" class=input>
<%set rsc=server.CreateObject("adodb.recordset")
rsc.open "select * from venshop_newssort order by sort_id desc",conn,1,1
do while not rsc.eof
sort_id=rsc("sort_id")%>
<option value="<%=rsc("sort_id")%>/0"<%if rs("a_sort")=rsc("sort_id") then%> selected<%end if%>><%=rsc("sort_name")%></option>
<%set rsn=server.CreateObject("adodb.recordset")
rsn.open "select * from venshop_newsnsort where sort_id="&sort_id&" order by nsort_id desc",conn,1,1
do while not rsn.eof
%>
<option value="<%=rsc("sort_id")%>/<%=rsn("nsort_id")%>"<%if rs("a_nsort")=rsn("nsort_id") then%> selected<%end if%>> <%=rsc("sort_name")%> >> <%=rsn("nsort_name")%></option>
<%rsn.movenext
loop
rsn.close
set rsn=nothing
rsc.movenext
loop
rsc.close
set rsc=nothing%></select></td></tr>
<tr><td height="15">新闻作者:<input type="text" name="a_author" size="20" class=input value="<%=rs("a_author")%>"> 转载地址:<input type="text" name="a_from" size="20" class=input value="<%=rs("a_from")%>"></td></tr>
<tr><td height="30" valign="top">新闻内容:<br><!--#include file="ad_in.asp"--></td></tr>
<tr><td height="30" valign="top"><input type="submit" value="更改新闻信息" name="B1" onClick="document.form.a_content.value = frames.message.document.body.innerHTML;" >
<input name="a_content" type="hidden" id="a_content" value=""></td>
</tr></form></table>
<%rs.close
set rs=nothing
end if
conn.close
set conn=nothing%><table cellSpacing="0" cellPadding="3" border="0" width="500"><tr><td height="20"></td></tr>
<tr><td bgcolor="#F2F2F2"><p style="LINE-HEIGHT: 150%"><font color="#FF0000">凡人网络购物系统V8.0 版权所有:</font><a target="_blank" href="http://www.venshop.com"><font color="#FF0000">凡人网络VenShop.Com</font></a><font color="#FF0000"><br>客服电话:010-80928177 QQ:739202/57152557 Email/Msn:</font><a href="mailto:Ser@VenShop.Com"><font color="#FF0000">Ser@VenShop.Com</font></a></td>
</tr></table>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -