Paypal以POST方式返回

时间:2017-09-18 10:43:02

标签: html http paypal paypal-sandbox

我正在尝试使用沙盒帐户测试Paypal第三方购物车按钮。按钮看起来像这样:

<form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post" target="_top" id="<some_id>">
    <input type="hidden" name="cmd" value="_cart">
    <input type="hidden" name="upload" value="1">
    <input type="hidden" name="business" value="<sandbox_account_email>">
    <input type="hidden" name="lc" value="DE">

    <input type="hidden" name="item_number_1" value="item_number_1_value">
    <input type="hidden" name="item_name_1" value="item_name_1_value" id="paypal-order-name">
    <input type="hidden" name="amount_1" value="10" id="paypal-last-amount">

    <input type="hidden" name="item_number_2" value="item_number_2_value">
    <input type="hidden" name="item_name_2" value="item_name_2_value">
    <input type="hidden" name="amount_2" value="45">

    <input type="hidden" name="currency_code" value="EUR">
    <input type="hidden" name="button_subtype" value="services">
    <input type="hidden" name="no_note" value="0">
    <input type="hidden" name="no_shipping" value="2">
    <input type="hidden" name="rm" value="2">
    <input type="hidden" name="bn" value="PP-BuyNowBF:btn_buynow_SM.gif:NonHostedGuest">
    <input type="image" id="order-pay-with-paypal" src="/files/1414/1874/7188/checkout-logo-large-de.png" intent="" in-highres-src="/files/9214/1874/7188/checkout-logo-large-de-2x.png" border="0" name="submit" disabled="true">

    <input type="hidden" name="return" value="https://somewheretoreturn.com/orders">
    <input type="hidden" name="charset" value="utf-8">
</form>

付款成功完成,重定向发生,但作为GET方法。我需要重定向到我的网站POSTrm变量设置为2,如documentation中所述,我还需要设置什么来执行POST请求?

0 个答案:

没有答案