Jump to content
Latest News: (loading..)
AFMatt

USPS - Parcel, Priority, & Express -- Support Forum

Recommended Posts

Hello,

 

I had some issues trying to get the USPS shipping modules to work that came with OS Commerce version 2.3.3 -- it only displayed "Library Mail" which I'll never use.

 

So, I made several copies of two files:

catalog/includes/modules/shipping/usps.php

and

catalog/includes/languages/english/modules/shipping/usps.php

 

Then modified them to display only USPS First-Class Parcel, USPS Priority Mail, and USPS Express Mail. They're new files, so you can simply drag and drop them into the appropriate folders without destroying your website. Once you've uploaded them, you can select each USPS shipping method in the Admin panel (Modules -> Shipping) then "Install" each new shipping module.

 

You can also alter the text that appears in each shipping method during checkout. Just go to you Admin panel (Tools -> Define Langauges). Then scroll down until you see "modules/shipping/uspsParcel.php", "modules/shipping/uspsPriority.php", and "modules/shipping/uspsExpress.php". Click on each one to change/redefine the MODULE_SHIPPING_USPSEXPRESS_TEXT_DURING_CHECKOUT text.

 

Each USPS shipping method appears as its own shipping entity during checkout:

post-308503-0-87274700-1376777747_thumb.jpg

 

I hope this helps other people who've been running into the same issues I did.

 

Feel free to update and re-post better/modified code.

 

Thanks,

Matt

Share this post


Link to post
Share on other sites

NOTE: I just realized that the USPS 1st Class Parcel method is limited to 13 ounces (0.8125 pounds). If the total weight of the order is greater than 0.8125 pounds, nothing will show up under USPS 1st Class Parcel.

 

I noted this limitation in the language files and I also added another shipping method (Standard Post). It's pretty much identical to Priority Mail as far as price is concerned, but not limited to 13 ounces like 1st Class Parcel was.

 

New package is posted (http://addons.oscommerce.com/info/8882) as version 1.1.

 

If you know how to modify the code so 1st Class Parcel doesn't display at all (the shipping title header is still there, but text ard price are not listed), please help and re-post code.

 

Thanks,

Matt

Share this post


Link to post
Share on other sites

First Class Parcel issue fixed. I added an update download to your package with a replacement file. Works great.

Share this post


Link to post
Share on other sites

Ever since the latest update at USPS, I have been unable to get USPS Shipping Methods to work. I removed it and installed this MOD and here is my problem...

 

1st - I only updated Priority Mail and the Express Mail shipping mods. I do not use Standard or Parcel so I did not upload them.

 

2nd - After running it and testing it, it seems that the Express Mail works but the Priority Mail does not. It displays on the checkout screen but it does not input any shipping costs.

 

Would anyone know what is going on with this?

 

To see it, my site is at http://www.maxatv.com

 

A test account was created using

- User Name: test@cardhost.com

- Password: 4050


Thanks,

Scooter

Share this post


Link to post
Share on other sites

Here is th fix for Priority Mail not working...

 

Open uspsPriority.php

 

Change line 137:

 

if ((strpos($type, 'Priority Mail 1') !== FALSE) && (strpos($type, 'Flat Rate') == FALSE)) {

 

to this:

 

if ((strpos($type, 'Priority Mail 2') !== FALSE) && (strpos($type, 'Flat Rate') == FALSE)) {

 

Just changing the 'Priority Mail 1' to 'Priority Mail 2' in the above line got it to work perfect!


Thanks,

Scooter

Share this post


Link to post
Share on other sites

Hi!

 

I am trying to offer free shipping on one category only (gift cards) with no weight, but cannot figure out how to offer free shipping. I have the weight set to 0, but it still charges $5.60 at checkout. Any help would be greatly appreciated. :)

Share this post


Link to post
Share on other sites

I noticed Express wasn't showing the price. Here's how I fixed it:

 

In uspsExpress.php on line 137

 

change this:

 

if ((strpos($type, 'Express 1') !== FALSE) && (strpos($type, 'Flat Rate') == FALSE)) {

 

to this:

 

if ((strpos($type, 'Express') !== FALSE) && (strpos($type, 'Flat Rate') == FALSE)) {

 

All that needed to be done is to take off the " 1" and leave "Express"

Share this post


Link to post
Share on other sites

@@AFMatt

Hello Mat i have latest version of OSC and downloaded the addon which is instructions to change priority 1 to priority 2....however i dont find the uspsPriority.php file. Where is it? thanks! Or if you have suggestions on how to get USPS shipping option to work?

I get the error. any ideas?

 

An error occured with the USPS shipping calculations.

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

 

Thanks!

Share this post


Link to post
Share on other sites

Hi !!

 

I copy the file usps to the shipping folder and i don't have the option to install the module, it is not on the list of the modules to install,

 

any idea why i can not see it ?

 

i don't know if i have to install from another side, i just copy the file into shipping folder.

 

Thanks in advance

Share this post


Link to post
Share on other sites

Hi Im getting the modules to show up but at the top in the admin area when I go to install them I see this.   Warning: include(/home/hutchaviation/public_html/store/includes/languages/english/modules/shipping/configure.php): failed to open stream: No such file or directory in/home/hutchaviation/public_html/store/admin/modules.php on line 141

Warning: include(): Failed opening '/home/hutchaviation/public_html/store/includes/languages/english/modules/shipping/configure.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in/home/hutchaviation/public_html/store/admin/modules.php on line 141

Share this post


Link to post
Share on other sites

Hi Im getting the modules to show up but at the top in the admin area when I go to install them I see this.   Warning: include(/home/hutchaviation/public_html/store/includes/languages/english/modules/shipping/configure.php): failed to open stream: No such file or directory in/home/hutchaviation/public_html/store/admin/modules.php on line 141

Warning: include(): Failed opening '/home/hutchaviation/public_html/store/includes/languages/english/modules/shipping/configure.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in/home/hutchaviation/public_html/store/admin/modules.php on line 141

 

Also having error saying that 

United States Postal Service - Standard Post shipping_usps.gif An error occured with the USPS shipping calculations.

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

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

×