Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

USPS module not returning Letter Post value


nicklestud

Recommended Posts

Hello. I have been running OSCommerce for about 2 years with the USPS module working fine. I noticed that this week USPS stopped sending my international customers the price for USPS Letter Post, and only sends them the shipping price for USPS Parcel Post. Since Parcel Post can often be much more than Letter Post, this is not desirable.

 

1. Is anyone now suddenly receiving this error also?

 

2. Is there a quick fix for this in the USPS module?

 

<_<

Link to comment
Share on other sites

I actually solved the problem. It looks like at the starting of the year when USPS changed their rates in January 8, 2006, they also changed their protocol for ship-assist. USPS no longer allows for dashes to be in the service type enquirey, and all words should be capitalized.

 

Here is a working example of the old USPS module:

	  $this->intl_types = array('GXG Document' => 'Global Express Guaranteed Document Service',
							'GXG Non-Document' => 'Global Express Guaranteed Non-Document Service',
							'Express' => 'Global Express Mail (EMS)',
							'Priority Lg' => 'Global Priority Mail - Flat-rate Envelope (Large)',
							'Priority Sm' => 'Global Priority Mail - Flat-rate Envelope (Small)',
							'Priority Var' => 'Global Priority Mail - Variable Weight Envelope (Single)',
							'Airmail Letter' => 'Airmail Letter-post',
							'Airmail Parcel' => 'Airmail Parcel Post',
							'Surface Letter' => 'Economy (Surface) Letter-post',
							'Surface Post' => 'Economy (Surface) Parcel Post');

 

Now When I took out all the dashes in Letter-post and capitalized the "p" in Post, it worked. Here is what the code now looks like in the USPS module.

 

	  $this->intl_types = array('GXG Document' => 'Global Express Guaranteed Document Service',
							'GXG Non-Document' => 'Global Express Guaranteed Non-Document Service',
							'Express' => 'Global Express Mail (EMS)',
							'Priority Lg' => 'Global Priority Mail - Flat-rate Envelope (Large)',
							'Priority Sm' => 'Global Priority Mail - Flat-rate Envelope (Small)',
							'Priority Var' => 'Global Priority Mail - Variable Weight Envelope (Single)',
							'Airmail Letter' => 'Airmail Letter Post',
							'Airmail Parcel' => 'Airmail Parcel Post',
							'Surface Letter' => 'Economy (Surface) Letter Post',
							'Surface Post' => 'Economy (Surface) Parcel Post');

 

I hope this helped anyone else.

:blush:

Link to comment
Share on other sites

Thanks... That was a big help. I noticed that my Global Priority Mail -Variable Weight Envelope was not working when I copied your code above. I removed the "Envelope" and it worked. Here is my change:

 

'Priority Var' => 'Global Priority Mail - Variable Weight (Single)',

Link to comment
Share on other sites

  • 1 month later...
Thanks... That was a big help. I noticed that my Global Priority Mail -Variable Weight Envelope was not working when I copied your code above. I removed the "Envelope" and it worked. Here is my change:

 

'Priority Var' => 'Global Priority Mail - Variable Weight (Single)',

 

 

THANKS FOR THAT! This solved my priority var problems, also! Thanks so much for posting.

Link to comment
Share on other sites

  • 6 months later...
I actually solved the problem. It looks like at the starting of the year when USPS changed their rates in January 8, 2006, they also changed their protocol for ship-assist. USPS no longer allows for dashes to be in the service type enquirey, and all words should be capitalized.

 

Here is a working example of the old USPS module:

	  $this->intl_types = array('GXG Document' => 'Global Express Guaranteed Document Service',
							'GXG Non-Document' => 'Global Express Guaranteed Non-Document Service',
							'Express' => 'Global Express Mail (EMS)',
							'Priority Lg' => 'Global Priority Mail - Flat-rate Envelope (Large)',
							'Priority Sm' => 'Global Priority Mail - Flat-rate Envelope (Small)',
							'Priority Var' => 'Global Priority Mail - Variable Weight Envelope (Single)',
							'Airmail Letter' => 'Airmail Letter-post',
							'Airmail Parcel' => 'Airmail Parcel Post',
							'Surface Letter' => 'Economy (Surface) Letter-post',
							'Surface Post' => 'Economy (Surface) Parcel Post');

 

Now When I took out all the dashes in Letter-post and capitalized the "p" in Post, it worked. Here is what the code now looks like in the USPS module.

 

	  $this->intl_types = array('GXG Document' => 'Global Express Guaranteed Document Service',
							'GXG Non-Document' => 'Global Express Guaranteed Non-Document Service',
							'Express' => 'Global Express Mail (EMS)',
							'Priority Lg' => 'Global Priority Mail - Flat-rate Envelope (Large)',
							'Priority Sm' => 'Global Priority Mail - Flat-rate Envelope (Small)',
							'Priority Var' => 'Global Priority Mail - Variable Weight Envelope (Single)',
							'Airmail Letter' => 'Airmail Letter Post',
							'Airmail Parcel' => 'Airmail Parcel Post',
							'Surface Letter' => 'Economy (Surface) Letter Post',
							'Surface Post' => 'Economy (Surface) Parcel Post');

 

I hope this helped anyone else.

:blush:

 

This is interesting. Why does the 'Letter-post" matter and not the "Mail - Variable Weight" ? And why not the "Flat-rate Envelope"

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...