Ok, Using Paypal IPN, is it possible to have the paypal server send back a custom variable that I passed to it originally? Like, when they use the "buy now" button, I'd like it to send a custom "my_user_id" (or something) field... then when the IPN sends the data back to my server, have it reference the "my_user_id" that I sent it... Any ideas? Thanks I've never used paypal site integration services before, looks interesting...
yes, it's possible. check paypal docs or google a sample is here: http://www.oreillynet.com/pub/a/javascript/excerpt/paypalhacks_chap1/index.html
You can set those options up on the PayPal site when you create your buy now button. The button cannot be encrypted. <input type="hidden" name="cmd" value="_xclick"> <input type="hidden" name="business" value="$PAYPAL_EMAIL"> <input type="hidden" name="item_name" value="Clickable Links for '" . $post['post_title'] . "'"> <input type="hidden" name="item_number" value="$PAYPAL_ITEM_A"> <input type="hidden" name="amount" value="$PAYPAL_AMOUNT"> <input type="hidden" name="no_shipping" value="1"> <input type="hidden" name="return" value="$SITE_ROOT/index.php?page=admin&id=" . $post['post_id'] . ""> <input type="hidden" name="no_note" value="1"> <input type="hidden" name="currency_code" value="$PAYPAL_CURRENCY"> <input type="hidden" name="lc" value="US"> <input type="hidden" name="bn" value="PP-BuyNowBF"> [b]<input type="hidden" name="on0" value="press_release_id"> <input type="hidden" name="os0" value='" . $post['post_id'] . "'>[/b] <input type="image" src="https://$PAYPAL_URL/en_US/i/btn/x-click-but23.gif" border="0" name="submit" alt="Make the links in this press release clickable!"> Code (markup): on# is the name of the custom field os# is the value of the custom field On the recieving end you reference it using option_selection[#+1] So os0 is option_selection1 for a very good reason I'm sure. On the site you can set up two options. I'd recommend keeping the bulk of the information in a database and then using the options to keep a unique id to reference the rest of the information stored in the db.