📄 receive.asp
字号:
<!--#include file="conn.asp"-->
<!--#include file="md52.asp"-->
<!--#include file="webconfig.asp"-->
<%
if request.Cookies("BOB")("username")="" then
response.Redirect "user.asp"
response.End
end if
%>
<html><head><title><%=webname%>--佣金计划</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="images/css.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style2 {color: #0000FF}
-->
</style>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<!--#include file="webtop.asp"-->
<TABLE cellSpacing=0 cellPadding=0 width=778 align=center border=0>
<TBODY>
<TR>
<TD class=b width=7 background=image/b-l.gif> </TD>
<TD class=b vAlign=top align=left width=764><table width="760" align="center" border="0" cellspacing="0" cellpadding="0" class="table-zuoyou" bordercolor="#CCCCCC">
<tr>
<td width="100%" valign="top" align="center" bordercolor="#FFFFFF" bgcolor="#FFFFFF"><table width="100%" align="center" border="0" cellspacing="0" cellpadding="0">
<tr>
<td background="images/class_bg.jpg" height=50> <img src="images/ring02.gif" width="23" height="15" align="absmiddle"> <a href=index.asp><%=webname%></a> >> 支付平台</td>
</tr>
</table>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td><table width=100% border="0" cellpadding="5" cellspacing="0" class="table-xia" bgColor=#f1f1f1>
<TR>
<TD bgColor=#ffffff colspan=19 height=1></TD>
<tr>
<td width="88%" colspan="8"><%
'该页面为支付完成后获取返回的参数及处理.....
'获取参数
v_oid=request("v_oid")
v_pmode=request("v_pmode")
v_pstatus=request("v_pstatus")
v_pstring=request("v_pstring")
v_md5info=request("v_md5info")
v_amount=request("v_amount")
v_moneytype=request("v_moneytype")
v_md5money=request("v_md5money")
v_md5=request("v_md5")
key="test"
if request("v_md5info")="" then
response.Write("v_md5info:空值")
response.end
end if
'md5校验
text = v_oid&v_pstatus&v_amount&v_moneytype&key
md5text = trim(md5(text))
'按md5检验情况输出结果 Ucase转换为大写
if Ucase(md5text)<>Ucase(v_md5) then
response.write("error")
else
response.write("received")
'或response.write "sent',依据商品物流特征决定。
'提示:仅是对校验码校验通过不表示该支付结果是成功只意味着该信息是由网银传回
'校验成功需对传回的v_pstatus参数做判断,其中1或20都意味着支付成功(只是支付状态分非实时和实时两种),30表示支付失败
'如果商户涉及实时售卡,请对返回的金额与数据库中原始金额做大小判断,以防恶意行为
'操作数据库
'''''''''''''''''''''开始写入数据库''''''''''''''''''''
'cn.close
'set cn=nothing
'set rs=nothing
'-----------------------------------------------
'若有错误发生
If Err.Number <> 0 Then
Response.Write "error" & Err.Number & "<br>"
Response.Write "error" & Err.Source & "<br>"
Response.Write "error" & Err.Description & "<br>"
Else
End If
'-----------------------------------------------
'关闭资料库
'-----------------------------------------------
end if
%>
<!--
以下是打印出所有接收数据的结果,供编程人员参考
-->
<table width="93%" border="0">
<tr>
<td><p align="center"><b><font color="#FF0000">提示:</font> 您网上在线支付情况反馈如下:</b><br>
<br>
此次交易编号: <%=v_oid%></p>
<p align="center">支付金额:<%=v_amount%> </p>
<p align="center">
<% if v_pstatus=1 then
zhuangtai = "支付已提交,但已对您的非实时银行卡已经进行扣款 "
%>
支付已提交,但已对您的非实时银行卡已经进行扣款
<%elseif v_pstatus=20 then
zhuangtai = "在线支付已经支付成功"
%>
在线支付已经支付成功
<%elseif v_pstatus=30 then
zhuangtai = "在线支付失败!"
%>
在线支付失败!
<%end if%>
</p>
<%
set BOB=server.CreateObject("adodb.recordset")
BOB.open "select * from [user] where username='"&request.Cookies("BOB")("username")&"' ",conn,1,3
if BOB.recordcount>0 then
yucun=BOB("yucun")
BOB("yucun")=yucun+v_amount
BOB.update
BOB.close
set BOB=nothing
%>
<div align="center">预存款充值成功,进入[<a href="user.asp" ><font color=red>会员中心</font></a>]
</div>
<%end if%>
<p></p></td>
</tr>
</table>
<p> </p>
</tr>
</table></td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
</table></TD>
<TD class=b width=7 background=image/b-r.gif><IMG height=1
src="image/tm.gif" width=1></TD>
</TR>
</TBODY>
</TABLE>
<!--#include file="service.asp"-->
<!--#include file="copyright.asp"-->
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -