Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Problem after paying with PayPal


glammabags

Recommended Posts

Posted

I posted this earlier, but it seems that I was not very clear with my problem ... hope someone can shed some light this time!

 

I am in testing mode ... Autoreturn with Paypal is set up for Checkout-process.php, in order to process the order and display it in the store and NORMALLY it should then redirect itself to Checkout-success.php.

 

That is exactly what is in the html code at the end of checkout_process.php:

 

// load the after_process function from the payment modules

$payment_modules->after_process();

 

$cart->reset(true);

 

// unregister session variables used during checkout

tep_session_unregister('sendto');

tep_session_unregister('billto');

tep_session_unregister('shipping');

tep_session_unregister('payment');

tep_session_unregister('comments');

 

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

 

require(DIR_WS_INCLUDES . 'application_bottom.php');

 

BUT it is just not happening!!! Also, I seem to be having a problem with LOGIN. I "login" ... add items to the shopping cart and when I try to go to checkout it asks me to login again! ... maybe these 2 problems are linked??

 

Thanks a lot!!!!

Posted

OK... I know someone out there must be facing the same problem ... I don't want to be alone on this one!

 

I am pretty much ready to go live and this is setting me back ... basically if someone pays with PayPal, they should be directed to CHECKOUTPROCESS through Autoreturn, right? Otherwise, the order is not processed and the client is charged but I have no way to know what he ordered. I know that he ordered and paid xx amount cause I get an INP from Paypal, but no description of what he bought.

 

So, how can I fix this?

 

1) autoreturn at paypal is set to checkout process, but it redirects itself to LOGIN. Maybe the system is logging out the customer so the checkout process is not completed?

 

2) if a customer decides to pay with paypal and then not return to my shop ... let's say, when the page is redirecting itself the customer chooses to visit another page, the process is not completed and I am in the same dilemma as before.

 

Am I rambling here? any ideas of how to solve this???

Posted

Please check in filenames.php

what is defined for FILENAME_CHECKOUT_SUCCESS. It should be

  define('FILENAME_CHECKOUT_SUCCESS', 'checkout_success.php');

 

Also, you may review your settings in paypal end since you may define the return URL on paypal profile.

 

Thanks

GS

Best Regards,
Gaurav

Posted
Please check in filenames.php

what is defined for FILENAME_CHECKOUT_SUCCESS. It should be

  define('FILENAME_CHECKOUT_SUCCESS', 'checkout_success.php');

 

Also, you may review your settings in paypal end since you may define the return URL on paypal profile.

 

Thanks

GS

 

Thanks a lot GS but....

 

1) I have checked filenames.php and the code is already just as you mention it

2) I have double-checked my paypal settings and the AUTORETURN is: http://mywebsite.com/shop/checkout_process.php

 

Any more ideas?

Posted
Thanks a lot GS but....

 

1) I have checked filenames.php and the code is already just as you mention it

2) I have double-checked my paypal settings and the AUTORETURN is: http://mywebsite.com/shop/checkout_process.php

 

Any more ideas?

Isn't that what it is suppossed to be?

Posted
Isn't that what it is suppossed to be?

 

Well ... if that's what it's supposed to be, why after a customer pays with paypal, they are directed to the LOGIN page instead of the CHECKOUT SUCCESS page ... and worse of all the order does not display in admin at all. ... meaning, the client is charged by paypal I have no way to know what the customer ordered!

Posted
Well ... if that's what it's supposed to be, why after a customer pays with paypal, they are directed to the LOGIN page instead of the CHECKOUT SUCCESS page ... and worse of all the order does not display in admin at all. ... meaning, the client is charged by paypal I have no way to know what the customer ordered!

Oh, it is probably an issue with sessions, unless you have ssl and are directing to http, or you have do not have ssl and are directing to https.

Posted
Oh, it is probably an issue with sessions, unless you have ssl and are directing to http, or you have do not have ssl and are directing to https.

Yes, I agree with Coopco's assesment, most probably sessions are getting dropped during payout process.

I would like to help you with this, however each test would require me to purchase something from your store :blink:

 

There are few things that you could check and update.

a. Last page before submitting for paypal check-out - view source code of the page and note what are the values for each

<input type=hidden ... tags.

b. After you have made payment, during redirection - does it come to checkout_success.php and then gets redirected to login.php by any chance? You may again view source on paypal page to check what are the hidden variables being passed.

c. Is your site SSL Enabled, and is paypal returning back to http://yoursite.com~~ or https://yoursite.com ?

 

Hope this would give us some direction to proceed further.

 

Cheers

GS

Best Regards,
Gaurav

Posted
Yes, I agree with Coopco's assesment, most probably sessions are getting dropped during payout process.

I would like to help you with this, however each test would require me to purchase something from your store :blink:

 

I think you could find something you might like in my store to buy ;)

 

Thanks for the advice ... I will do as you suggest and let you know what comes out of it. One thing is certain: my site is not SSL enabled (yet).

Posted
I think you could find something you might like in my store to buy ;)

It would be wonderful to buy, but the cost of shipping to india would upset my budget ;)

 

However quick questions for you

a. Are you using paypal.php or paypal_ipn.php?

In code it is assumed that your site would be ssl enabled. However it is not a MUST condition.

 

checkout_process.php first line is to check if customer session is available, and if not, send to login.php ,so indeed as we thought, session is getting dropped after payout.

 

Please check which module is installed, and we can check further.

 

Thanks

Gaurav

Best Regards,
Gaurav

Posted
It would be wonderful to buy, but the cost of shipping to india would upset my budget ;)

 

We might be able to arrange something! ;)

 

a) it must be paypal.php ... as I never installed paypal_ipn.php. Truth is, and sorry if I sound super-ignorant here, I have no idea what the difference would be if I had ipn anyway...

 

B) grateful if you can have a look at the checkout_process code :blush:

 

and.... many thanks!!!

Posted
a. Are you using paypal.php or paypal_ipn.php?

 

I am double-checking my paypal settings and

 

I do have INSTANT PAYMENT NOTIFICATION is OFF and I have Payment Data Transfer ON. Should this be the other way around, maybe?

Posted

Turn IPN == ON please and test.

 

Thanks

Gaurav

 

PS: Sorry, haven't been able to reply to your post earlier. Been a busy Sunday... :(

Best Regards,
Gaurav

Posted
Turn IPN == ON please and test.

 

YESSSSSS ... with your help I managed to figure it out ...

 

setup IPN to ON with URL directed to checkout_process.php

and Autoreturn also ON but directed to checkout_success.php

and switched OFF PDT

 

and it's working :lol:

 

Many many thanks!!!!!!

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...