<!--#include file="Conn.asp"-->
<!--#include file="cookies.asp"-->
<%
dim id,modify,sd_title,sd_Author,sd_CopyFrom,sd_ArtKeyWord,sd_ArtDescription,sd_Content,sd_Hits,sd_hot
id=request("id")
if id="" then
response.write "参数丢失!"
Response.End
end if
sd_title=request("sd_title")
sd_Author=request("sd_Author")
sd_CopyFrom=request("sd_CopyFrom")
sd_ArtKeyWord=request("sd_ArtKeyWord")
sd_ArtDescription=request("sd_ArtDescription")
sd_Content=request("sd_Content")
sd_Hits=request("sd_Hits")
sd_hot=request("sd_hot")
modify=request("modify")
if modify="yes" then
if sd_title="" or sd_Hits="" then
response.write "<script language=javascript>alert('文章名称、浏览次数必须填写!');history.go(-1);</script>"
else
set r=server.createobject("adodb.recordset")
r.open "select * from sd_article where id="&id,conn,1,3
if not r.eof then
r("id")=id
r("sd_title")=sd_title
r("sd_Author")=sd_Author
r("sd_CopyFrom")=sd_CopyFrom
r("sd_ArtKeyWord")=sd_ArtKeyWord
r("sd_ArtDescription")=sd_ArtDescription
r("sd_Content")=sd_Content
r("sd_Hits")=sd_Hits
r("sd_hot")=sd_hot
r.update
Response.Write "<script language=javascript>alert('修改成功！');this.location.href='sd_article.asp';</script>"
end if
r.close
set r=nothing
end if
end if
%>
<HTML>
<HEAD>
<TITLE>商奇软件 www.583344.com</TITLE>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"> 
<LINK href="images/Admin_css.css" type=text/css rel=stylesheet>
</HEAD>
<BODY>
<form action="sd_article_02.asp" method="post" onSubmit="return load_content();">
<%
set r=server.createobject("adodb.recordset")
r.open "select * from sd_article where id="&request("id"),conn,1,3
if not r.eof then
%>
<table height="1" border="0" cellpadding="3"  cellspacing="1" bgcolor="#F2F9E8" class="admintable1">
  <tr>
    <td colspan="2" class="admintitle">修改文章</td>
  </tr>
  <tr>
    <td width="20%" height="30" align="right" bgcolor="#FFFFFF">文章标题：</td>
    <td width="80%" bgcolor="#FFFFFF"><input name="sd_title" value="<%=r("sd_title")%>" size="50"> * 不可为空</td>
  </tr>
  <tr>
    <td height="30" align="right" bgcolor="#FFFFFF">关键词：</td>
    <td bgcolor="#FFFFFF"><input name="sd_ArtKeyWord" value="<%=r("sd_ArtKeyWord")%>" size="90"> 用 , 分割</td>
  </tr>
  <tr>
    <td height="30" align="right" bgcolor="#FFFFFF">页面描述：</td>
    <td bgcolor="#FFFFFF"><textarea name="sd_ArtDescription" cols="88" rows="4"><%=r("sd_ArtDescription")%></textarea></td>
  </tr>
  <tr>
    <td height="30" align="right" bgcolor="#FFFFFF">文章作者：</td>
    <td bgcolor="#FFFFFF"><input name="sd_Author" value="<%=r("sd_Author")%>" size="35"></td>
  </tr>
  <tr>
    <td height="30" align="right" bgcolor="#FFFFFF">文章来源：</td>
    <td bgcolor="#FFFFFF"><input name="sd_CopyFrom" value="<%=r("sd_CopyFrom")%>" size="35"></td>
  </tr>
  <tr>
    <td height="30" align="right" bgcolor="#FFFFFF">是否推荐：</td>
    <td bgcolor="#FFFFFF"><input name="sd_hot" type="radio" value="1" <%if r("sd_hot")=1 then%>checked="checked"<%end if%>>是　<input name="sd_hot" type="radio" value="0" <%if r("sd_hot")=0 then%>checked="checked"<%end if%>>否</td>
  </tr>
  <tr>
    <td height="30" align="right" bgcolor="#FFFFFF">浏览次数：</td>
    <td bgcolor="#FFFFFF"><input name="sd_Hits" value="<%=r("sd_Hits")%>" size="10" onKeyUp="value=value.replace(/[^\d.]/g,'')" onbeforepaste="clipboardData.setData('text',clipboardData.getData('text').replace(/[^\d.]/g,''))"></td>
  </tr>
  <tr>
    <td height="30" align="right" bgcolor="#FFFFFF">内容：<br><br>* 不可为空</td>
    <td bgcolor="#FFFFFF"><SCRIPT language="javascript">
var Sm="";//----编辑器的网址
var Se="SDEdit/";//----编辑器的文件夹
var sy="919B9C";//----边框深一点的颜色
var qy="ECE9D8";//----背景浅一点的颜色
var by="FCFCFC";//----背景白色的底纹
var an="sd_content";//----所要编辑的文本框名称
</script>
<SCRIPT language="JavaScript" src="SDEdit/sdEdit.js" charset="gb2312"></SCRIPT>  
<textarea name="sd_content" id="sd_content" cols="88" rows="8" style="display:none;"><%=r("sd_content")%></textarea></td>
  </tr>
  <tr>
    <td height="30" align="right" bgcolor="#FFFFFF"></td>
    <td bgcolor="#FFFFFF"><input name="id" value='<%=r("id")%>' type='hidden'><input name="modify" value="yes" type="hidden"><input type="submit" value="确认修改"></td>
  </tr>
</table>
<%
end if
r.close
set r=nothing
%>
</form>
<!--#include file="sd_copy.asp"-->
</BODY>
</HTML>
