📄 p2sadd_do.asp
字号:
<%@ LANGUAGE = VBScript %>
<!--#include file="conn.asp"-->
<!--#include file="checklogin.asp"-->
<%
rs.Open "Select * From config",Conn
EmailAddress = rs ("EmailAddress")
rs.Close
P2SName = Request ("P2SName")
P2SLink = Request ("P2SLink")
P2SImg = Request ("P2SImg")
P2SText = Request ("P2SText")
P2SType = Request ("P2SType")
P2SValuation = Request ("P2SValuation")
P2SSignup = Request ("P2SSignup")
P2SLimit = Request ("P2SLimit")
P2SOwner = Request ("P2SOwner")
P2SValid = Request ("P2SValid")
P2SPeriod = Request ("P2SPeriod")
P2sTotalSignup = Request ("P2sTotalSignup")
GroupForP2C = Request ("GroupForP2C")
If P2SName = "" Then
Conn.Close
Set Conn = nothing
Session ("Message") = "您必须输入注册广告名称。"
Response.Redirect "error.asp"
Response.End
End If
If P2SLink = "" Then
Conn.Close
Set Conn = nothing
Session ("Message") = "您必须输入注册广告连接。"
Response.Redirect "error.asp"
Response.End
End If
If P2SValuation = "" Then
Conn.Close
Set Conn = nothing
Session ("Message") = "您必须输入注册广告价值。"
Response.Redirect "error.asp"
Response.End
End If
If P2SLimit = "" Then
Conn.Close
Set Conn = nothing
Session ("Message") = "您必须输入注册广告注册限制。"
Response.Redirect "error.asp"
Response.End
End If
If P2SSignup = "" Then
P2SSignup = 0
End if
If P2SOwner = "" Then
P2SOwner = EmailAddress
End if
If P2SPeriod = "" Then
P2SPeriod = -1
End if
If P2SValid = "" Then
P2SValid = True
End if
P2SName = "P2S_" & P2SName & ""
rs.Open "Select * From p2s Where P2SName = '" & P2SName & "'",Conn
If not Rs.Eof Then
rs.Close
Set rs = nothing
Conn.Close
Set Conn = nothing
Session ("Message") = "同名注册广告已经存在。"
Response.redirect "error.asp"
Response.End
End if
rs.Close
rs.Open "Insert Into p2s(P2SName, P2SLink, P2SImg, P2SText, P2SType, P2SValuation, P2SSignup, P2SLimit, P2SOwner, P2SValid, P2SPeriod, P2sTotalSignup, GroupForP2C) values('" & P2SName & "', '" & P2SLink & "', '" & P2SImg & "', '" & P2SText & "', '" & P2SType & "', '" & P2SValuation & "', '" & P2SSignup & "', '" & P2SLimit & "', '" & P2SOwner & "', " & P2SValid & ", '" & P2SPeriod & "', '" & P2sTotalSignup & "', '" & GroupForP2C & "')",Conn
Conn.Close
Set Conn = nothing
Session ("Message") = "注册广告增加成功。"
Response.redirect "success.asp"
Response.End
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -