<!--#include file="admin_conn.asp"-->
<%
if request("news_flm")="请选择分类"  then
response.write "<script LANGUAGE='javascript'>alert('请选择文章分类！');history.go(-1);</script>"
response.End
end if
if request("News_pt")="" then
response.write "<script LANGUAGE='javascript'>alert('请输入文章标题！');history.go(-1);</script>"
response.End
end if
if request("News_test")="" then
response.write "<script LANGUAGE='javascript'>alert('请输入文章内容！');history.go(-1);</script>"
response.End
end if

Set rs = Server.CreateObject("ADODB.Recordset")
rs.open "SELECT  * From news2",conn,1,3
rs.addnew
rs("news_flm")=request("news_flm")
rs("news_pt")=request("news_pt")
rs("shoppic")=request("shoppic")
rs("ss")=request("ss")
rs("news_test")=request("news_test")
'rs("News_zz")=request("News_zz")
if request("news_gd") <> "" then
rs("news_gd")=request("news_gd")
end if 
if request("news_hot") <> "" then
rs("news_hot")=request("news_hot")
end if
if request("news_new") <> "" then
rs("news_new")=request("news_new")
end if  
rs.update
rs.close
set rs=nothing
conn.close
set conn=nothing
response.write "<script language='javascript'>"
response.write "alert('添加成功！');"
response.write "location.href='news.asp';"			
response.write "</script>"
%>
 
