receive3.asp
上传用户:btntkt
上传日期:2021-04-16
资源大小:5296k
文件大小:2k
源码类别:

WEB源码(ASP,PHP,...)

开发平台:

DOS

  1. <!--#include file="md5.asp"-->
  2. <%
  3. '''''''''
  4.  ' @Description: 快钱网关接口范例
  5.  ' @Copyright (c) 上海快钱信息服务有限公司
  6.  ' @version 2.0
  7. '''''''''
  8. key ="99billKeyForTest" '''商户密钥
  9. merchant_id = request.querystring("merchant_id") '''获取商户编号
  10. orderid =  request.querystring("orderid") '''获取订单编号
  11. amount =  request.querystring("amount") '''获取订单金额
  12. date =  request.querystring("date") '''获取交易日期
  13. succeed =  request.querystringr("succeed") '''获取交易结果,Y成功,N失败
  14. mac =  request.querystring("mac") '''获取安全加密串
  15. merchant_param =  request.querystring("merchant_param") '''获取商户私有参数
  16. couponid = (String)request.getParameter("couponid") '''获取优惠券编码
  17. couponvalue = (String)request.getParameter("couponvalue")  '''获取优惠券面额
  18. '''生成加密串,注意顺序
  19. ScrtStr = "merchant_id=" & merchant_id & "&orderid=" & orderid & "&amount=" & amount & "&date=" & mydate & "&succeed=" & succeed & "&merchant_key=" & key
  20. mac=md5(ScrtStr) 
  21.  v_result="失败"
  22. if ucase(mac)=ucase(mymac)   then 
  23. if succeed="Y"   then '''支付成功
  24. v_result="成功"
  25. '''
  26. '''#商户网站逻辑处理#
  27. '''
  28. else '''支付失败
  29. end if
  30. else '''签名错误
  31. end if
  32. %>
  33. <!doctype html public "-//w3c//dtd html 4.0 transitional//en" >
  34. <html>
  35. <head>
  36. <title>快钱99bill</title>
  37. <meta http-equiv="content-type" content="text/html; charset=gb2312" />
  38. </head>
  39. <body>
  40. <div align="center">
  41. <table width="259" border="0" cellpadding="1" cellspacing="1" bgcolor="#CCCCCC" >
  42. <tr bgcolor="#FFFFFF">
  43. <td width="68">订单编号:</td>
  44.   <td width="182"><%=orderid%></td>
  45. </tr>
  46. <tr bgcolor="#FFFFFF">
  47. <td>订单金额:</td>
  48.   <td><%=amount%></td>
  49. </tr>
  50. <tr bgcolor="#FFFFFF">
  51. <td>支付结果:</td>
  52.   <td><%=v_result%></td>
  53. </tr>
  54.   </table>
  55. </div>
  56. </body>
  57. </html>