Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

USPS International Shipping Trouble


phenam

Recommended Posts

I'm using USPS shipping method and anything from the US works fine but if someone places an order out of the states it gives you options for the different shipping methods but when you go to check out no matter what you chose it sets your shipping to "Global Express Guaranteed Document Service" which is very expensive. Does anyone know if there is something I need to change or update? I'm not even sure where to start. Any help would be much appreciated! Thanks so much in advance!

Link to comment
Share on other sites

Hello! I found the fix. I'll post here too so you don't have to fish for it.

 

Change this:

      $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');

 

To this:

      $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 (Single)',
                               'Airmail Letter' => 'Airmail Letter-post',
                               'Airmail Parcel' => 'Airmail Parcel-post',
                               'Surface Letter' => 'Economy (Surface) Letter-post',
                               'Surface Post' => 'Economy (Surface) Parcel-post');

 

I am still having trouble with my shipping rates rounding up. Does anyone have a fix for this? Say priority mail is $3.85 at check out it rounds it up to $4.00. Any help would be great!

Link to comment
Share on other sites

  • 1 year later...
  • 4 weeks later...
thanks a million! this seems to have fixed the problem with global priority being changed to expensive express mail when checking out!

 

 

I'm also having this problem but I'm not seeing any differences in the codes you posted...plus I think this is a really old thread because they also don't look like they're the updated terms for USPS. Any help at all? My international customers are extremely frustrated.

 

I also do not want to add some new module to my site. I just want to edit what I have. Every time I try to add a new module it wrecks the whole store.

Link to comment
Share on other sites

I'm also having this problem but I'm not seeing any differences in the codes you posted...plus I think this is a really old thread because they also don't look like they're the updated terms for USPS. Any help at all? My international customers are extremely frustrated.

 

I also do not want to add some new module to my site. I just want to edit what I have. Every time I try to add a new module it wrecks the whole store.

 

 

Yes, this problem also started for my site as of the new rates implementation on 14 May. Except that changing the current OSC code doesn't seem to do anything when the rates are actually being accessed from the USPS website. Maybe the problem is there ? I've tried several 'fixes' and deletions with no improvement at all.

Link to comment
Share on other sites

with the new rates, I'm back to the same problem again! Intl. customers are still getting the expensive global express rate no matter what they choose as their shipping option. Has anyone figured this out yet!! Need help!

Link to comment
Share on other sites

I FINALLY got the international shipping rates module to work!!! Only took me 2 days... Here's the error message I got after my first attempt to install the updated shipping module:

 

An error occured with the USPS shipping calculations.

If you prefer to use USPS as your shipping method, please contact the store owner.

 

I then did these steps (I'm a total novice at SQL so didn't understand what to do at first, but these instructions worked).

 

I opened phpmyadmin, selected the configuration table (the one entitled configuration) on the left, checked the 'set_function' field on the right side and clicked the 'change' icon over to the left of it. I set the 'TYPE' to 'TEXT', blanked out the 'Length/Value' box so that it's empty, and left the 'Null' and 'Default' settings to 'NULL'. Then I saved. It seemed to go fine.

 

Then I applied the other update my clicking "SQL" at the top and copying it into the "Run SQL query/queries on database" box and clicking "Go."

 

I went back to the shipping module section and reselected the international options I wanted to offer. When I did a test purchase it worked perfectly! whew!

 

Laurie

Link to comment
Share on other sites

I FINALLY got the international shipping rates module to work!!! Only took me 2 days... Here's the error message I got after my first attempt to install the updated shipping module:

 

An error occured with the USPS shipping calculations.

If you prefer to use USPS as your shipping method, please contact the store owner.

 

I then did these steps (I'm a total novice at SQL so didn't understand what to do at first, but these instructions worked).

 

I opened phpmyadmin, selected the configuration table (the one entitled configuration) on the left, checked the 'set_function' field on the right side and clicked the 'change' icon over to the left of it. I set the 'TYPE' to 'TEXT', blanked out the 'Length/Value' box so that it's empty, and left the 'Null' and 'Default' settings to 'NULL'. Then I saved. It seemed to go fine.

 

Then I applied the other update my clicking "SQL" at the top and copying it into the "Run SQL query/queries on database" box and clicking "Go."

 

I went back to the shipping module section and reselected the international options I wanted to offer. When I did a test purchase it worked perfectly! whew!

 

Laurie

 

Hi,

I too am having the same problem. Where did you get this info Laurie? What is the SQL query that you executed? Thanks!

Link to comment
Share on other sites

Hi,

I too am having the same problem. Where did you get this info Laurie? What is the SQL query that you executed? Thanks!

 

hi Christina,

if you download the USPS shipping method 2.8 contribution (in the Contributions under shipping methods), it has all of the changes you need to make including the SQL changes. I'm not sure I can 'recreate' how I did this, but following the instructions given, then doing the second SQL change as explained below solved the problem. If you need more help, ask and I'll attempt to go into more detail about what I did (if I can remember!)

Laurie

Link to comment
Share on other sites

  • 1 month later...

Has anyone found a true fix to the International Shipping Problem?

 

The problem is that no matter what shipping option the customer chooses, Global Express Guaranteed is always chosen on the confirmation page.

Link to comment
Share on other sites

I have been getting this error when ever someone from another country (outside USA) tries to order. This has been since May when USPS switched up their services:

 

An error occured with the USPS shipping calculations.

If you prefer to use USPS as your shipping method, please contact the store owner.

 

I have finally found a solution that worked for me. This was after trying everything I found in the forums including re-installing the USPS Methods 2.8d and the mysql commands. The USPS Methods for international shipping was still broken.

 

What I discovered was that the domestic shipping options worked fine, but the international quote didnt work. I read the XML data that USPS spits out and found that the names of the services were not the exact names listed in the usps.php array around line 49.

 

Once you have edited the file bellow, save it and replace it on your site. Then go to the admin log in area and uninstall it and then install it so that it reloads the new php file with the corrected services.

 

edit this file: catalog\includes\modules\shipping\usps.php

here is what I changed to get the module to display the correct international shipping rates:

 

around line number 49:

 

replace:

 

$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 (Single)',

'Airmail Letter' => 'Airmail Letter Post',

'Airmail Parcel' => 'Airmail Parcel Post',

'Surface Letter' => 'Economy (Surface) Letter Post',

'Surface Post' => 'Economy (Surface) Parcel Post');

 

with

 

$this->intl_types = array('GXG Document' => 'Global Express Guaranteed',

'GXG Non-Document' => 'Global Express Guaranteed Non-Document Rectangular',

'GXG Non-Document Large' => 'Global Express Guaranteed Non-Document Non-Rectangular',

'Express' => 'Express Mail International (EMS)',

'Express Envelope' => 'Express Mail International (EMS) Flat Rate Envelope',

'Priority Flat Rate Box' => 'Priority Mail International Flat Rate Box',

'Priority Flat Envelope' => 'Priority Mail International Flat Rate Envelope',

'Priority Box' => 'Priority Mail International',

'First Class' => 'First-Class Mail International');

 

 

 

around line number 153:

 

replace:

tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Int\'l Shipping Methods', 'MODULE_SHIPPING_USPS_TYPES_INTL', 'GXG Document, GXG Non-Document, Express, Priority Lg, Priority Sm, Priority Var, Airmail Letter, Airmail Parcel, Surface Letter, Surface Post', 'Select the international services to be offered:', '6', '15', 'tep_cfg_select_multioption(array(\'GXG Document\', \'GXG Non-Document\', \'Express\', \'Priority Lg\', \'Priority Sm\', \'Priority Var\', \'Airmail Letter\', \'Airmail Parcel\', \'Surface Letter\', \'Surface Post\'), ', now())");

 

with:

tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Int\'l Shipping Methods', 'MODULE_SHIPPING_USPS_TYPES_INTL', 'GXG Document, GXG Non-Document, Express, Express Envelope, Priority Flat Rate Box, Priority Flat Envelope, Priority Box, First Class', 'Select the international services to be offered:', '6', '15', 'tep_cfg_select_multioption(array(\'GXG Document\', \'GXG Non-Document\', \'Express\', \'Express Envelope\', \'Priority Flat Rate Box\', \'Priority Flat Envelope\', \'Priority Box\', \'First Class\'), ', now())");

Link to comment
Share on other sites

  • 4 weeks later...

thobry

 

I cannot find the file path you have listed: catalog\includes\modules\shipping\usps.php

 

Please let me know where to place the code you have listed. Please be very detailed in steps to follow. I have not worked in this database for very long, and am still getting used to the program. I really appreciate your help.

 

Thomi Ditch

Link to comment
Share on other sites

  • 1 year later...

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...