addnew.asp

来自「手机入网登记管理」· ASP 代码 · 共 30 行

ASP
30
字号
<!--#include file="conn.asp"--> 
<%if session("password")<>"" then%>
<%
if request("xh")="" then
	response.write "<script language=JavaScript>" & chr(13) & "alert('填写电话号码');" & "history.back()" & "</script>" 
	Response.End
end if
bj=Replace(Request.Form("bj"),"'","''")  
DZ=Replace(Request.Form("DZ"),"'","''") 
xh=Replace(Request.Form("xh"),"'","''") 
user=Replace(Request.Form("user"),"'","''")
dz=Replace(Request.Form("dz"),"'","''")  
kc=Replace(Request.Form("kc"),"'","''")
cj=Replace(Request.Form("cj"),"'","''")
FY=Replace(Request.Form("FY"),"'","''")
ZSHF=Replace(Request.Form("ZSHF"),"'","''")
SJHF=Replace(Request.Form("SJHF"),"'","''")
xq=Replace(Request.Form("xq"),"'","''")
bb=Replace(Request.Form("bb"),"'","''")
lx=Replace(Request.Form("lx"),"'","''")
biglocation=Replace(Request.Form("biglocation"),"'","''") 
smalllocation=Replace(Request.Form("smalllocation"),"'","''")  
set savebbs=conn.execute("insert into bbs1(bj,xh,user,dz,kc,cj,FY,ZSHF,SJHF,xq,bb,lx,biglocation,smalllocation)values('"&bj&"','"&xh&"','"&user&"','"&dz&"','"&kc&"','"&cj&"','"&FY&"','"&ZSHF&"','"&SJHF&"','"&xq&"','"&bb&"','"&lx&"','"&biglocation&"','"&smalllocation&"')")
response.write "<script language=JavaScript>" & chr(13) & "alert('添加成功!');"&"window.location.href = 'res.asp'"&" </script>"
set savebbs=nothing 
%>  
<%else
Response.Redirect "admpost.asp"
end if%>

⌨️ 快捷键说明

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