Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

PayPal Express Checkouts redirected to Payment Page


twocats_us

Recommended Posts

I was hoping that someone might be able to shed a light on this problem some of my customers have had. They click on the PayPal icon to complete the Express Checkout Option but once they click confirm order they are redirected back to the payment page. It thinks that they have not selected a payment option at all. I am using OSCommerce v2.2 with the Direct PayPal Payment module. Has anyone seen this and know what changes or fixes I need to make? Thank you.

Link to comment
Share on other sites

I was hoping that someone might be able to shed a light on this problem some of my customers have had. They click on the PayPal icon to complete the Express Checkout Option but once they click confirm order they are redirected back to the payment page. It thinks that they have not selected a payment option at all. I am using OSCommerce v2.2 with the Direct PayPal Payment module. Has anyone seen this and know what changes or fixes I need to make? Thank you.

 

Fixed! Just in case anyone out there runs into this problem and would like to know how to fix it. I located another topic finally through google search that indicated that the MODULE_PAYMENT_INSTALLED was coming back null even though there is more than 1 payment module installed.

 

So around line 31 in the checkout_process.php file there is a redirect to the payment page with an if statement. Remove the "tep_not_null(MODULE_PAYMENT_INSTALLED)" from that if statement and it works just fine. If someone has a better way of fixing this please do tell.

 

Thank you!

Edited by twocats_us
Link to comment
Share on other sites

Fixed! Just in case anyone out there runs into this problem and would like to know how to fix it. I located another topic finally through google search that indicated that the MODULE_PAYMENT_INSTALLED was coming back null even though there is more than 1 payment module installed.

 

So around line 31 in the checkout_process.php file there is a redirect to the payment page with an if statement. Remove the "tep_not_null(MODULE_PAYMENT_INSTALLED)" from that if statement and it works just fine. If someone has a better way of fixing this please do tell.

 

Thank you!

 

Hey yes I have found the same problem. Could you post the line of code before the change and after or just the changed line?

Cheers

Link to comment
Share on other sites

  • 2 weeks later...

Hey yes I have found the same problem. Could you post the line of code before the change and after or just the changed line?

Cheers

 

It would appear that I have not entirely fixed the problem. There is another line of code that checks to see if the modules are installed, as well as making sure the payment object exists, which it should.

 

Here is that original code: (around line 71)

 

if ( ( is_array($payment_modules->modules) && (sizeof($payment_modules->modules) > 1) && !is_object($$payment) ) || (is_object($$payment) && ($$payment->enabled == false)) ) {

tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));

}

 

Have not tried it yet but will be testing out this changed code:

 

if ( (!is_object($$payment) ) || (is_object($$payment) && ($$payment->enabled == false)) ) {

tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));

}

 

As for the other code that was changed in addition:

 

if (!tep_session_is_registered('payment')) {

tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));

}

 

What I would really like to do is to find out how to fix it so that it sees that payment modules are in fact installed. That would be the proper way to fix it I believe. I just haven't found any thing any where to help with this.

 

AND the weird part about all of this is that if the customer logs in before they go to paypal to use the express checkout it does not happen!

 

Hope that helps, let me know if you figure it out.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...