I am a photographer and provide clients with preview and 'BuyNow' options on my website.
The way this is being done at the moment is that each image has an 'image number' and its the customers responsibility to provide this correctly at the PayPal checkout.
What I would like to do is to pass the current pages URL into the checkout via a variable option in PayPal.
Each image has its own unique page, and therefore I can identify the image they want from this.
Giving 'IMG_1234' and the image they want to buy.
I have spent a few weeks crawling through the internet and found the following option:
<input type="hidden" name="item_name" value="<?php echo basename($_SERVER['SCRIPT_FILENAME'],".php");?>" readonly />
I'm not even sure if the syntax is correct in the code, and all that gets passed through to the checkout is the actual code, and not the URL.
Can any of you guys help?