How to send Shipping address to Paypal, when using Paypal IPN

泄露秘密 提交于 2019-12-14 03:39:31

问题


I am trying to integrate Paypal IPN to an application which I am developing. And I am stuck in a problem which is regarding shipping address. I need to know how to send the address variables to Paypal, as a request so that User can see that address on paypal. Please tell me the variables which should be sent to paypal, which paypal treats as shipping address(or delivery address).

Thanks in advance.


回答1:


To send the shipping address to PayPal you need to modify your PayPal submit form.

Using this will let you to override PayPal stored address:

<input type="hidden" name="address_override" value="1">

And then use this variables to override PayPal stored address:

<input type="hidden" name="first_name" value="Spendthrift">
<input type="hidden" name="last_name" value="Richer">
<input type="hidden" name="address1" value="123 Money St">
<input type="hidden" name="city" value="Dollarwood">
<input type="hidden" name="state" value="AB">
<input type="hidden" name="zip" value="4811">
<input type="hidden" name="country" value="CA">

From PayPal.com

The payer is shown the passed-in address but cannot edit it. No address is shown if the address is invalid, such as missing required fields like country, or if the address is not included at all.

Here are the references:
https://developer.paypal.com/docs/classic/paypal-payments-standard/integration-guide/formbasics/#id08A6F0T0JQN



来源:https://stackoverflow.com/questions/5733926/how-to-send-shipping-address-to-paypal-when-using-paypal-ipn

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!