Reputation: 21
I would like to setup a simple PayPal button on my website, however I need to send and receive a few custom parameters.
I have generated some basic button code: (eg https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=MXR9J7XQ4SW3N)
I need to pass and receive back 2 parameters: - Customer_ID - Product_ID
Usually I would do something like this: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=MXR9J7XQ4SW3N&*Customer_ID=1&Product_ID=1*
But I would I receive those parameters back after the payment is complete?
Many thanks for your help.
Upvotes: 2
Views: 1404
Reputation: 2340
Unless you're using variables that PayPal would recognize the ones you're trying to add will be ignored and dropped by PayPal - same with if you're using hosted buttons (you can't modify the variables and values for a hosted button through HTML or just appending them to a URL).
You can use custom
and item_number
to pass your "customer_id" and "product_id" values to PayPal. You'll get them back through PDT and IPN as well.
Upvotes: 2