php - Using Dynamic URL for PayPal Redirect -
i have orders form, in following variables chosen: price, currency, quantity (+ others). form submitted through jquery: $("#paypal_form").submit();
everything fine , transaction goes on normally, in end paypal doesn't redirect specified url in form. let me know correct setting paypal is, because in paypal's options choice fill in url (otherwise won't allow set auto return setting), url dynamic , changed based on transaction id. looks this: <input type="hidden" name="return" value="myreturnurl.php?orderid=88273882717a72734">
here form (fields filled in js):
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top" id="paypal_form"> <p> <input type="hidden" name="cmd" value="_xclick" /> <input type="hidden" name="charset" value="utf-8" /> <input type="hidden" name="business" value="info@mail.com" /> <input type="hidden" name="item_name" value="citation building" /> <input type="hidden" name="item_number" value="1" /> <input type="hidden" name="amount" value="" /> <input type="hidden" name="currency_code" value="usd" /> <input type="hidden" name="return" value="" /> <input type="hidden" name="cancel_return" value="id=0" /> <input type="hidden" name="bn" value="business_buynow_wps_se" /> <input type="image" src="https://www.paypal.com/en_us/i/btn/btn_buynowcc_lg.gif" name="submit" alt="buy now" />
thanks in advance.
it's 'return' have right now, needs absolute url. e.g.;
<input type="hidden" name="return" value="http://stackoverflow.com/questions/17970910/using-dynamic-url-for-paypal-redirect">
Comments
Post a Comment