Hello
I'm trying to make a donation page for a project, and i need this donation to be associated to a data the user is giving.
After the donation is done, i want back this data to use it.
I'm working as sandbox credentials now, so here is my HTML code on donation page :
<form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post" target="_top"> <input type="hidden" name="cmd" value="_s-xclick" /> <input type="hidden" name="hosted_button_id" value="XXXXXXXXXX" /> <input type="hidden" name="custom" value='{}' id="custom_input" /> <input type="hidden" name="return" value="http://xxxx.xxxx.xxxxx/donation/success" /> <input type="hidden" name="cancel_return" value="http://xxxx.xxxx.xxxxx/donation" /> <input type="hidden" name="rm" value="2" /> <input type="image" src="http://xxxx.xxxxx.xxxxx/image/paypal-donate.png" border="0" name="submit" title="PayPal - The safer, easier way to pay online!" alt="Donate with PayPal button" /> <img alt="" border="0" src="https://www.sandbox.paypal.com/en_FR/i/scr/pixel.gif" width="1" height="1" /> </form>
Then, there is a field outside of this form, that i watch with javascript and when the user change it, i report the value into the custom field in the paypal donation form.
First thing, despite i have enabled the return default page in my account settings, and provided a return overriding field in the form, when the donation is done, i'm always brought to the default paypal success page, with a return to merchant site link or wait few seconds to be redirected automatically.
I expected to not see that page but instantly mine http://xxxx.xxxx.xxxxx/donation/success
Second thing, after the redirection activating or by clicking the link, i'm redirected to the right page : http://xxxx.xxxx.xxxxx/donation/success
On this page at the moment, written with PHP, i'm just dumping all $_GET and $_POST variables, and these are absolutely empties.
I searched a lot on forums, stackoverflow, google, tried to make multiple buttons, i can't get it to work as expected.
Can someone help me on this, i'm totally lost ?
Sincerly
... View more