?? receive.asp
字號(hào):
<!--#include file="../pay_function.asp"-->
<!--#include file="168settings.asp"-->
<!-- #include file="168char.asp" -->
<%
'on error Resume Next
vip=Request.ServerVariables("Remote_Addr") '提交者IP地址
v_orderid=Request.Form("v_orderid") '168注冊(cè)中心反饋的定單號(hào)
v_orderdate=Request.Form("v_orderdate") '定單成交時(shí)間
v_price=Request.Form("v_price") '定單成交價(jià)格
v_province=Request.Form("v_province") '用戶提交時(shí)選擇的省份
v_city=Request.Form("v_city") '用戶提交時(shí)選擇的城市(地區(qū))
'########################################################################
'參數(shù)排列:0用戶,1級(jí)別號(hào),2級(jí)別名,3金額,4點(diǎn)數(shù)/有效期
'########################################################################
v_custom1=Split(Request.Form("v_custom1"),"|") '自定義字段1
v_custom2=Request.Form("v_custom2") '自定義字段2
v_md5=Request.Form("v_md5") '返回的加密字符串
v_pstatus=Request.Form("v_pstatus") '定單成功反饋的字符串,有1和0兩種情況。主要用于驗(yàn)證是否屬正常反饋。
if v_pstatus="1" then
if v_orderid="" or v_orderdate="" or v_price="" or v_md5="" then%>
<script language=vbscript>
MsgBox "非法反饋:反饋的數(shù)據(jù)不正確!"
location.href = "<%=myhomepage%>"
</script>
<%end if
'以下程序驗(yàn)證返回的加密字符串是否正確
encrypt_string=Ucase(trim(md5(v_orderid&v_price®_userid®_key)))
if v_md5<>encrypt_string then%>
<script language=vbscript>
MsgBox "致命錯(cuò)誤:返回的加密字符串不正確,您是非法提交!"
location.href = "<%=myhomepage%>"
</script>
<%Response.end
end if
'驗(yàn)證返回的加密字符串是否正確程序結(jié)束
'以下程序防止用戶是否多次刷新成功頁面,最好的方法是您做成從自己的數(shù)據(jù)庫(kù)中檢測(cè)v_orderid定單號(hào)是否已成交,如果已成交,就不顯示頁面。
if session("reg168_orderid")<>"" then
if session("reg168_orderid")=v_orderid then%>
<script language=vbscript>
MsgBox "錯(cuò)誤:同一定單成交頁面不允許多次刷新或提交!"
location.href = "<%=myhomepage%>"
</script>
<%Response.end
else
session("reg168_orderid")=v_orderid
end if
else
session("reg168_orderid")=v_orderid
end if
'為防止用戶多次刷新成功頁面,使緩存的頁面立即過期
Response.Expires=0
'########################################################################
' v_custom1參數(shù)排列:0用戶,1級(jí)別號(hào),2級(jí)別名,3金額,4點(diǎn)數(shù)/有效期
'########################################################################
if session("username")<>"" then
r_name = session("username")
else
r_name = v_custom1(0)
end if
if v_custom1(1)>1 then
'/////////////////////////////////////////////////////////////
' 用戶包月升級(jí)函數(shù):目標(biāo)用戶名,級(jí)別,金額,有效期/月,支付用戶
'/////////////////////////////////////////////////////////////
call update_user(v_custom1(0),v_custom1(1),v_price,v_custom1(4),r_name)
else
'/////////////////////////////////////////////////////////////
' 用戶加點(diǎn)數(shù)函數(shù):目標(biāo)用戶名,級(jí)別,金額,加入點(diǎn)數(shù),支付用戶
'//////////////////////////////////////////////////////////////
call update_user_ds(v_custom1(0),v_custom1(1),v_price,v_price*vip_money(1),r_name)
end if
else
Response.write "支付失敗"
end if%>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -