Jump to content
Sign in to follow this  
xgarrison

USPS Domestic Shipping Troubles

Recommended Posts

I saw jayman11's post in a prior topic:

 

-Quote:

"Did we have some name changes again today??? USPS domestic is all out of whack...checked a couple other OSCommerce sites and they have the same issues.......Names are no longer defined properly on the shipping method page and no matter what you select it defaults to whatever is on the top of the order for your shipping."

---

 

Our blowgun site is experiencing this same problem. We are using the latest usps.php, and we ship domestic methods only. Had to remove express mail option as customers were complaining this was the only (expensive) option, and the site wouldn't let them change it. I now have customers limited to priority mail only...

 

Anybody have any info?

Share this post


Link to post
Share on other sites

It looks like the days in transit is broken as well. At least I think I remember it working when it was first installed.

For now I'll have to disable express as well, spent some time looking for the problem but didn't find anything.

 

-Tim

Share this post


Link to post
Share on other sites
I saw jayman11's post in a prior topic:

 

-Quote:

"Did we have some name changes again today??? USPS domestic is all out of whack...checked a couple other OSCommerce sites and they have the same issues.......Names are no longer defined properly on the shipping method page and no matter what you select it defaults to whatever is on the top of the order for your shipping."

---

 

Our blowgun site is experiencing this same problem. We are using the latest usps.php, and we ship domestic methods only. Had to remove express mail option as customers were complaining this was the only (expensive) option, and the site wouldn't let them change it. I now have customers limited to priority mail only...

 

Anybody have any info?

 

I replied to jayman11's post in the other thread, but I'll post here too so more people see it. I just fixed this issue on my site. It seems that the USPS is now returning the method ID's in all uppercase and it's using a case sensitive match that's causing it to think you haven't chosen a shipping method. It then chooses the first available method, which happens to be Express. All you need to do to fix it is edit usps.php and update the keys in the $this-types array to be uppercase.

 

Edit: tarheit, I don't use days in transit myself, so I can't say for sure, but I'd bet this fixes that too.

Edited by Kadaki

Share this post


Link to post
Share on other sites

Worked like a charm.....just need to change your catalog/includes/modules/shipping/usps.php

 

from

$this->types = array('First Class'=> 'First-Class Mail (2-5 Days)',
						 'Priority' => 'Priority Mail (2 Days)',
					   'Express' => 'Express Mail');

if (MODULE_SHIPPING_USPS_PEONLY == 'True'){
$this->types = array('Express' => 'Express Mail',
					   'Priority' => 'Priority Mail')

 

to

$this->types = array('FIRST CLASS' => 'First-Class Mail (2-5 Days)',
						 'PRIORITY' => 'Priority Mail (2 Days)',
					   'EXPRESS' => 'Express Mail');

if (MODULE_SHIPPING_USPS_PEONLY == 'True'){
$this->types = array('EXPRESS' => 'Express Mail',
					   'PRIORITY' => 'Priority Mail')

 

Jayman

Share this post


Link to post
Share on other sites

Tim,

 

I am using USPS Methods 2.8d with the May 14th update.

 

I have attempted to make the changes you touched upon but am not able to get the USPS display to function properly.

 

Can you, or anyone else, please be more specific as to what exact changes need to be made in which files and how to update the records in the configuration?

 

Thanks in advance for your help.

 

Regards,

 

Dick

 

That worked, thanks. Note: if you are using USPS Methods like I am ( http://addons.oscommerce.com/info/487 ), then you'll need to change several places in the code as well as update the records in the configuration.

 

-Tim

Share this post


Link to post
Share on other sites

I was having the same problem every order was defaulting to Express Mail and customers could not change it no matter what they did. I followed Jaymans code change and it is working fine now.

Thank you Jayman

Paul

www.fullahotair.com

Share this post


Link to post
Share on other sites
I've posted the modified usps.php and script to take care of the database changes with the contribution.

http://addons.oscommerce.com/info/487

 

-Tim

 

Tim, thanks for the post. A couple things though.

 

1. The change in the modified usps.php file don't look CAPITALIZED to me, is that correct?

 

2. Compared to Jay's post above

 

$this->types = array('FIRST CLASS' => 'First-Class Mail (2-5 Days)',

'PRIORITY' => 'Priority Mail (2 Days)',

'EXPRESS' => 'Express Mail');

 

if (MODULE_SHIPPING_USPS_PEONLY == 'True'){

$this->types = array('EXPRESS' => 'Express Mail',

'PRIORITY' => 'Priority Mail')

 

I can't find in my original file or the new file the if (MODULE_SHIPPING_USPS_PEONLY.... bit of code. Maybe it is customized for something non-standard and not needed for most stores?

 

3. Once the initial CAPITALIZATION in done like in the $this->types = array('FIRST CLASS' => 'First-Class Mail lines is the only other thing needed to do is to run the "update.sql" that is posted in the the new usps_2.9.2a contribute?

 

 

Thanks for everyones help!

 

P.S. this seems senseless on USPS part.

 

Regards

Mike Talmadge

http://thoughtout.biz

Edited by THOUGHTOUT

Share this post


Link to post
Share on other sites

It has not fixed itself. It's still working like it did yesterday.

 

International works fine, it's domestic that's messed up.

 

-t

Share this post


Link to post
Share on other sites

As for now (9:45 AM Pacific Time) it still has not fixed itself. Changing the code above also did not work for me. I just disabled the Express module for now.

 

Seems that USPS change was not good on their part, causing confusion. Or perhaps was since they are going to get TONS of Express orders today rather than Priority and First Class. Probably a better profit margin for them.

 

Disabling the Express in the module worked so now customer can choose FC or Priority. I am leaving Express turned off until USPS gets their act together. I have DHL and UPS for customers to turn to anyway for fast shipments.

Share this post


Link to post
Share on other sites

Does anyone know a contact to verify if this USPS API change is here to stay? It would be so simple for them to correct this rather than each of us, right?

Share this post


Link to post
Share on other sites

Just to chime in real quick;

my includes/modules/shipping/usps.php

$Id: usps.php,v 1.47 2003/04/08 23:23:42 dgw_ Exp $

 

Had the same problem defaulting customers to express, all usps shipping types displaying in caps.

changed lines 46 - 49

	  $this->types = array('EXPRESS' => 'Express Mail',
					   'FIRST CLASS' => 'First-Class Mail',
					   'PRIORITY' => 'Priority Mail',
					   'PARCEL' => 'Parcel Post');

just capitalized the words.

 

It works! Problem solved.

 

This is the power of open source. Thank you all!!!

Share this post


Link to post
Share on other sites

I had a shipping module that I installed, Free Shipping and it no longer works since I updated with the update contrib re issue of capitalization.

 

Tha admin part of modules no longer showing possibility to remove or install modules, so I can't remove it to see if re-installing it would help.

 

Any suggestions?

Share this post


Link to post
Share on other sites

We can get First Class to display as an option. Any ideas? It is clearly in the code


Kym

Projects Director @ ozEworks.com

Share this post


Link to post
Share on other sites

Should have said cannot get ... It is in the Admin and the database configuration but not shown as an option on the site


Kym

Projects Director @ ozEworks.com

Share this post


Link to post
Share on other sites

I called USPS API dev people at (800) 344-7779. They claim that this is only happening to OSC customers. They claim that they are still sending tags in lowercase. Any way to verify this. They say that we changed something. If they are returning in lowercase then what is going on?

 

The fix works. Besure to change or uninstall reinstall the module in admin to take effect (don't just edit the module).


Kendall

Brooklyn, New York USA

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  

×