繁体   English   中英

贝宝(Paypal)经常性捐赠

[英]Recurring paypal donation

我有一个网页,我希望将经常性捐款整合到其中。

我有以下HTML代码,该代码允许用户插入任何金额,然后单击“捐赠”以提交该金额。

我想要的是一个厚框,一旦按下该框,该框就会重复出现。 提一下,我在Paypal上有一个企业帐户。

<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
    <input type="hidden" name="cmd" value="_donations">
    <input type="hidden" name="business" value="email@domain-x.com">
    <input type="hidden" name="lc" value="US">
    <input type="hidden" name="item_name" value="Widget Fund">
    <input type="hidden" name="item_number" value="W-001">
    <input type="hidden" name="no_note" value="0">
    <input type="hidden" name="cn" value="Add special instructions to the seller:">
    <input type="hidden" name="no_shipping" value="2">
    <input type="hidden" name="currency_code" value="USD">
    <!-- --><br />
    Please enter your donation amount: (Example - 10.00)<br />
    <input type="text" name="amount" size="5"><br />
    <input type="hidden" name="bn" value="PP-DonationsBF:btn_donateCC_LG.gif:NonHosted"><br />
    <input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!"><br />
    <img alt="" border="0" src="https://www.paypalobjects.com/en_GB/i/scr/pixel.gif" width="1" height="1"><br />
</form>

PayPal按钮具有描述付款时间表的参数; 如果您发送这些参数,则PayPal将设置定期付款而不是单次付款。 变量均在此处描述:

https://developer.paypal.com/docs/classic/paypal-payments-standard/integration-guide/Appx_websitestandard_htmlvariables/#id08A6HI00JQU

每月5美元(无需试用或大量付款)将为:a3 = $ 5(金额)t3 = M(条款类型为月)p3 = 1(每1个月)

...,然后还有其他参数(在文档中)可提供更多功能和设置。

我遇到了同样的问题,花了很多时间试图创建一个向用户询问金额和付款次数的表单。 实际上,键没有填充a3,t3或p3! 关键是... cmd字段!

像这样:

      <input type="hidden" name="cmd" value="_donations">

您将获得独特的捐赠付款(并且您必须使用“金额”字段来指定金额)

要获得捐款,您必须使用:

    <input type="hidden" name="cmd" value="_xclick-subscriptions  ">

在这种情况下,您必须使用“ a3”字段表示金额,“ t3”字段表示“时间类型”(D =每天,M =每个月,Y =每年),而“ p3”表示时间数。 您还必须使用“ src”和“ srt”。 因此,EG:

      a3 = 15  // You donate 15 dollar
      t3 = M  // the unit for time is "month"
      p3 = 1   // The paiment will occur each "unit of time" so each month
      src = 1   // There is a "recurrent paiement"
      srt = 6  // which will happened 6 time

因此,在此示例中,用户将在6个月内每月支付15美元

或EG:

     a3 = 20  // You donate 30 dollar
     t3 = M  // the unit for time is "month"
     p3 = 3   // The paiment will occur each "unit of time" so each 3 month
     src = 1   // There is a "recurrent paiement"
     srt = 4  // which will happened 4 time

因此,在此示例中,用户将支付20美元,每3个月支付4次。 因此,一月,四月,七月,依此类推。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM