Jump to content
Sign in to follow this  
greasemonkey

PayPal Express how to ignore cheapest shipping - in store pickup

Recommended Posts

I see... 

 

I'm definitely no expert (far from it in fact) but I would guess PP is doing something else in the 6 seconds allowed... or is ignoring the 6 seconds completely? Or the callback timeout is not the issue at all.

 

I retest many more times;

 

With both external shipping mods de-activated, leaving only the flat rate (in store) and zone module and the time comes in between 0.4 and 1 seconds (one time was 2.2. seconds).

With 1 external module activated time comes in between 1.4 and 1.7.

With both active time comes between 1.7 and 2.4 seconds.

 

The instant update works every time with the flat rate and zone module only.

 

And does not ever work with either external module activated UNLESS the customer is logged in.

Share this post


Link to post
Share on other sites

Ok @@Harald Ponce de Leon, if you have any more idea's I would be happy to test them. Please let me know.... I would love to get this working as designed.

 

I have 1 last question;

 

I have turned the instant update feature off for now, so the customer is now redirected to our checkout_confirmation page and the "correct" (cheapest) shipping option is chosen because (I presume) of the changes made in include/classes/shipping.php mentioned in my first post

            //if ($rates[$i]['cost'] < $cheapest['cost']) {
			//edit to remove $0.00 from cheapest shipping... sb//
			if ($rates[$i]['cost'] < $cheapest['cost'] && $rates[$i]['cost'] > 0) {

As an alternative to instant update because it would seem this problem is wide spread - is there a way to have the customer return to (an alternate maybe) "checkout_shipping" page where they can then select an alternative shipping method then move to checkout_confirmation (skipping checkout_payment)?

 

Or maybe an alternative checkout_confimation page where they can select (with a radio button or drop down) alternative shipping methods? Yes, as I type this I realize this probably wouldn't work...

Share this post


Link to post
Share on other sites

The problem is not wide-spread ;)

 

Try the following:

 

In ext/modules/payment/paypal/express.php, around line 591 change from:

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

to:

tep_session_register('ppec_right_turn');
$ppec_right_turn = true;
tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));

:heart:, osCommerce

Share this post


Link to post
Share on other sites

 

The problem is not wide-spread ;)

Please accept my apologies if I came across insulting...

 

Tried and tested with both external modules active, one 1 active and both in-active... no change...

Share this post


Link to post
Share on other sites

@@greasemonkey, if you're able to configure your webserver, you can see exactly how long PayPal requires to make the Instant Update request.

 

For Apache:

 

http://www.ducea.com/2008/02/06/apache-logs-how-long-does-it-take-to-serve-a-request/

 

Nginx: (request_time)

 

http://wiki.nginx.org/HttpLogModule#log_format


:heart:, osCommerce

Share this post


Link to post
Share on other sites

@@Harald Ponce de Leon testing is going very well. I just have one concern about the change made that redirects back to checkout_shipping. It would seem I have to hit "confirm order" twice on 2 separate checkout_confimation pages.

 

Once looks "normal" the second checkout_confimation page has the PP message stack asking to confirm the order

 

Please review and confirm your order below. Your order will not be processed until it has been confirmed.

 

Is there a way to remove this duplicate step?

 

Thanks again Harald.

Edited by greasemonkey

Share this post


Link to post
Share on other sites

Thank you for the reply Harald the flow is;

 

Shopping Cart -> PayPal -> Checkout Shipping -> Checkout Confirmation -> checkout confirmation -> Checkout Success

Share this post


Link to post
Share on other sites

@@Harald Ponce de Leon just testing a little more... the duplicate checkout_confimation only happens with instant update set false.

 

So, to your earlier point (this is not wide spread), I can probably live with this work around as is. Again, I can't thank you enough for the help.

 

I'll let you know if something else comes up.

Share this post


Link to post
Share on other sites

I can't edit my above post... Funny, on sandbox the duplicate checkout_confimation page happens with instand update set to false.

 

When I switch to live credentials it is reversed??? Weird....

Share this post


Link to post
Share on other sites

Still struggling away with this instant update feature. I have an open support ticket with PayPal, however they don't seem very keen to reply.

 

For now, I have un-done the change suggested by Harald to redirect back to checkout_shipping and then to checkout_confirmation - it was givind difficulty with customers discount codes when logged in.

 

So, my current setup is normal... with instant update off. 

 

@@Harald Ponce de Leon my only question today is uft related.

 

I'm in Canada and run English only - everything is UTF8. However, PayPal Express seems to be double encoding (I think that is the technical term?). Causing issues with French accents.

 

I've changed, in includes/modules/payment/paypal_express.php all 4 instances of (and one instance in ext/modules/payment/paypal/express.php) 

$post_string .= $key . '=' . urlencode(utf8_encode(trim($value))) . '&';

To

$post_string .= $key . '=' . urlencode(trim($value)) . '&';

Is this acceptable?

 

Didn't help my bigger problem un-fortunately :(  :(  :(

Share this post


Link to post
Share on other sites

Hi all, my struggles continue with PayPal Express 3.0. However, I'm determined to get this thing to work as advertised. Here is my current setup... then I have a few questions;

 

1) the paypal express module and ext files are all stock - with exception of the UFT changes mentioned in my last post. All other changes mentioned above only served to confuse me/things.

2) I have instant update ON and SSL enabled (of course I have a SSL cert from a name brand provider).

3) I have removed the "checkout with paypal" button from the shopping cart page - until I can figure out why the shipping rates are not being forwarded unless a customer is logged in

 

Here are my questions;

 

1) Should auto return in my PP profile be on or off? I cannot find a concrete answer for PP express in the manner - currently it is on? However, it would seem it does not matter?

2) Should auto return be true/on what should the return URL be? Currently its set to /checkout_process.php?

 

And probably more difficult to answer....  I was having an issue where shipping rates for one of my shipping modules where doubling when redirected back to our site and I thought PP Express wasn't suppose to redirect back to checkout_confimation.php..I found this post http://forums.oscommerce.com/topic/301688-upsxml-135-packing-variable-reference-lost/ relating to doubling shipping rates and applied similar fixes to my Canada Post shipping module and now customers are not redirect back to checkout_confimation... so I think I've fixed but... HOWEVER;

 

3) Under what circumstance will PayPal Express, with instant update ON have a customer redirect back to checkout_confirmation.php? -

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×