asp 一些支付接口

2019-01-13 07:07:04王振洲

    
    '商家可以把一些辅助信息放在mp列表中,当从YeePay易宝平台返回时,还可以原样取出商家设定的一些信息。可以提供商家临时保存信息的功能
    sMctProperties = ""            '(可保持为空)

    '如果直接到YeePay网关设定为空即可,而在商家端选择银行的情况下请参见银行列表
    frpId=""                    '(可选)

    '调用签名函数生成签名串
    sNewString = getReqHmacString(orderId,amount,cur,productId,productCat,productDesc,merchantCallbackURL,sMctProperties,frpId)

%>
<html>
<head>
<title>易宝支付</title>
</head>
<body onLoad="document.yeepay.submit()">
    <form name="yeepay" action="<%=nodeAuthorizationURL%>" method="post">
        <input type="hidden" name="p0_Cmd" value="<%=messageType%>">
        <input type="hidden" name="p1_MerId" value="<%=merchantId%>">
        <input type="hidden" name="p2_Order" value="<%=orderId%>">
        <input type="hidden" name="p3_Amt" value="<%=amount%>">
        <input type="hidden" name="p4_Cur" value="<%=cur%>">
        <input type="hidden" name="p5_Pid" value="<%=productId%>">
        <input type="hidden" name="p6_Pcat" value="<%=productCat%>">
        <input type="hidden" name="p7_Pdesc" value="<%=productDesc%>">
        <input type="hidden" name="p8_Url" value="<%=merchantCallbackURL%>">
        <input type="hidden" name="p9_SAF" value="<%=addressFlag%>">
        <input type="hidden" name="pa_MP" value="<%=sMctProperties%>">
        <input type="hidden" name="pd_FrpId" value="<%=frpId%>">        
        <input type="hidden" name="hmac" value="<%=sNewString%>">
    </form>
</body>
</html>


3.yeepayCommon.asp

<%
    Dim mctSDK
    Dim nodeAuthorizationURL
    Dim messageType
    Dim addressFlag
    nodeAuthorizationURL = "https://www.yeepay.com/app-merchant-proxy/node"    '扣款请求URL 无需更改
    messageType="Buy"            '消息类型
    addressFlag="0"                '需要填写送货信息 0:不需要 1:需要