juss_me Posted December 11, 2004 Posted December 11, 2004 My question involves the Paypal auto-return feature, and where to point the link. I have seen 2 answers to this question in this forum, so I am very unsure what to do. One answer is to point the paypal link to my checkout_success page. There is text that must be added per paypal rules (ie: Thank you for your payment. Your transaction has been completed, and a receipt for your purchase has been emailed to you. You can log in to your paypal account to see details of this transaction.) Now, it seems to me, although I may be very wrong, that if I put that text on the success page, it will show up no matter if my customer chooses paypal or to pay by check or money order (my only other payment choice atm.) In other words, it seems to me that if my customer chooses "pay by check or money order" they are going to see text on the success page saying "....log in to your paypal account..." and this does not seem correct. The other answer I have seen in these forums is to link it to my checkout_process page. However, first off, I can't even manage to *see* this page in my store, and secondly, when looking at ...languages/english/checkout_process.php, I see no place where the mandatory paypal text can be added. (Perhaps being able to view this page on my site would help?) All comments and suggestions are vastly appreciated, as this needs to be cleared up for me. I'm hoping that this issue can be cleared up *without* suggesting a paypal contrib, as I have read that it is hard to install and to make work, and I have to pay someone else to do that work. I would rather just do it myself without the contrib. I know other folks are also confused on this issue, as I have been reading all the posts I can find on the subject, and it is less than clear what exactly to do. Thanks so much in advance, and if I am not very clear, please let me know and I will clear it up as best I can. Thanks, Dawn ;)
♥Vger Posted December 11, 2004 Posted December 11, 2004 The checkout_process.php file is a php script processing file and not a web page that appears on your website. The file of the same name at includes/languages/english/ just contains the text holders for the e-mail headings that are sent out to the customer. So, yes, the file to amend is includes/languages/english/checkout_success.php You can keep the PayPal text fairly innocuous by saying something like "If you paid via PayPal blah blah blah" However, although this is part of PayPal's Terms and Conditions, I don't know anyone who puts that text in. Vger
mhormann Posted December 11, 2004 Posted December 11, 2004 However, although this is part of PayPal's Terms and Conditions, I don't know anyone who puts that text in.<{POST_SNAPBACK}> True enough. I lately talked to one of their Dublin customer support personnel, pointing out the problem of 'PayPal-specific text' in an online shop that just MIGHT use other payment methods as well, and it seems that they're happy as long as you make absolutely clear to the customer that the transaction IS or HAS been processed and that they actually HAVE paid (or tried to). It's apparently just to give customers an immediate feedback which we want to do anyway. Since PayPal also tell the customer what's happening while they are on their site, it might be not exactly 'playing by the rules' but we can probably just live with saying 'it's been processed and you will get further notice by email' or the like. I have IPN payments 'on hold' here in Germany sometimes for 5-7 DAYS so the only way to let them know what's happening is (automated osC) email anyway. I'm actually thinking about changing the email text for 'payment on hold' and tell them that transferring money to their bank account first and THEN relaying it via PayPal takes some time and it's wiser to use a CC or have some money in their PP account... ? Has anybody DONE this already? I do not want to encourage anyone to disobey any agreed-upon terms here, but to my experience (and many others I've talked to regarding this matter), I think we all might just 'get by' using a more general approach?as long as we DO give positive feedback. Just my two cents... Regards, Matthias I don't want to set the world on fire—I just want to start a flame in your heart. osCommerce Contributions: Class cc_show() v1.0 – Show Credit Cards, Gateways More Product Weight v1.0
devosc Posted December 11, 2004 Posted December 11, 2004 If you're using the default oscommerce paypal payment module, then to achieve the above: in catalog/includes/modules/payment/paypal.php (line 92) find tep_draw_hidden_field('return', tep_href_link(FILENAME_CHECKOUT_PROCESS, '', 'SSL')) . and change to tep_draw_hidden_field('return', tep_href_link(FILENAME_CHECKOUT_PROCESS, 'paypal=true', 'SSL')) . then find (line 102) function after_process() { return false; } and change to function after_process() { global $HTTP_GET_VARS; if (isset($HTTP_GET_VARS['paypal']) && ($HTTP_GET_VARS['paypal'] == 'true')) { if(!tep_session_is_registered('paypal_customer')) tep_session_register('paypal_customer'); $paypal_customer = true; } return false; } then in catalog/includes/languages/english/checkout_success.php find define('TEXT_SUCCESS', 'Your order has been successfully processed! Your products will arrive at their destination within 2-5 working days.'); and replace with if (tep_session_is_registered('paypal_customer')) { define('TEXT_SUCCESS', 'Your order has been successfully processed! Your products will arrive at their destination within 2-5 working days.<br /><br />Thank you for your payment. Your transaction has been completed, and a receipt for your purchase has been emailed to you. You may log into your account at <a href="http://www.paypal.com" target="_blank">www.paypal.com</a> to view details of this transaction.'); tep_session_unregister('paypal_customer'); } else { define('TEXT_SUCCESS', 'Your order has been successfully processed! Your products will arrive at their destination within 2-5 working days.'); } In the above the text shown to customer is within the if (tep_session_is_registered('paypal_customer')) { ... } and the text for all other payments will be as defined within the else { .... } So when a payment is made by a PayPal customer the above will then show as Your order has been successfully processed! Your products will arrive at their destination within 2-5 working days. Thank you for your payment. Your transaction has been completed, and a receipt for your purchase has been emailed to you. You may log into your account at www.paypal.com to view details of this transaction. As also noted above, not all transactions are immediately processed, e.g. eChecks. The above text is the example provided by PayPal and may be suitably amended. I would also change line 32 from $this->form_action_url = 'https://secure.paypal.com/cgi-bin/webscr'; to $this->form_action_url = 'https://www.paypal.com/cgi-bin/webscr'; as this is now the correct url, remember to verify all payments within your PayPal account before shipping out the order. "Any fool can know. The point is to understand." -- Albert Einstein
devosc Posted December 11, 2004 Posted December 11, 2004 Actually, it's easier than that (was initially thinking about returning to checkout_success) So the first edit is not required, eg. no need to do anything to tep_draw_hidden_field('return', tep_href_link(FILENAME_CHECKOUT_PROCESS, '', 'SSL')) . and the second edit just becomes function after_process() { if(!tep_session_is_registered('paypal_customer')) tep_session_register('paypal_customer'); $paypal_customer = true; return false; } For the Auto-Return URL to specify in your PayPal account profile, just set it to your website homepage, the paypal payment module will override this URL but Auto-Return must be enabled in your PayPal account profile. "Any fool can know. The point is to understand." -- Albert Einstein
cmbyrne Posted December 11, 2004 Posted December 11, 2004 So, yes, the file to amend is includes/languages/english/checkout_success.php You can keep the PayPal text fairly innocuous by saying something like "If you paid via PayPal blah blah blah" <{POST_SNAPBACK}> That's what i did, worked just fine. Christina
juss_me Posted December 12, 2004 Author Posted December 12, 2004 Thanks everyone! I was away today, but will be working on this tomorrow. I appreciate all your answers! Thanks, Dawn
mhormann Posted December 12, 2004 Posted December 12, 2004 Now that IS a cool solution, Greg—The PayPal Expert at work... ;) Happy to see you back and so active! I don't want to set the world on fire—I just want to start a flame in your heart. osCommerce Contributions: Class cc_show() v1.0 – Show Credit Cards, Gateways More Product Weight v1.0
Recommended Posts
Archived
This topic is now archived and is closed to further replies.