Zen Cart Logo
Forums / Addon Shipping Modules / USPS Shipping Module [Support Thread]

USPS Shipping Module [Support Thread]

Sticky

Views: 77,349

Results 41 to 60 of 447
5 Apr 2021, 4:28 PM
#41
coastalpond avatar

coastalpond

New Zenner

Join Date:
Feb 2021
Location:
Georgia
Posts:
11
Plugin Contributions:
0

USPS Shipping Module [Support Thread]

I am new to Zencart, and working with installing the USPS mode, I think I got it install right.

  • /includes/modules/shipping/usps.php
    • /includes/languages/english/modules/shipping/usps.php
    • /includes/templates/template_default/images/icons/shipping_usps.gif

have it in test mode. I added a couple things to my cart, but when I go to my cart. Nothing is showing for USPS. It's like the Mod is not there or not working HELP

Any help would be appreciated.

5 Apr 2021, 4:49 PM
#42
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

Coastalpond:

I am new to Zencart, and working with installing the USPS mode, I think I got it install right.

  • /includes/modules/shipping/usps.php
    • /includes/languages/english/modules/shipping/usps.php
    • /includes/templates/template_default/images/icons/shipping_usps.gif

have it in test mode. I added a couple things to my cart, but when I go to my cart. Nothing is showing for USPS. It's like the Mod is not there or not working HELP

Any help would be appreciated.
Is that the current (2020-09-24 K11) version of USPS? Which version of Zen Cart is in use?

It would also help if you could post a screenshot of the current settings (obfuscating your USPS ID).

5 Apr 2021, 6:29 PM
#43
coastalpond avatar

coastalpond

New Zenner

Join Date:
Feb 2021
Location:
Georgia
Posts:
11
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

Yes current version k11 and 1.5.7 of zencart

5 Apr 2021, 6:31 PM
#44
coastalpond avatar

coastalpond

New Zenner

Join Date:
Feb 2021
Location:
Georgia
Posts:
11
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

settings
United States Postal Service

You will need to have registered an account with USPS at https://secure.shippingapis.com/registration/ to use this module

USPS expects you to use pounds as weight measure for your products.

USPS Version Date
2020-09-24 K11

Enable USPS Shipping
True

Full Name or Short Name
Long

Enter the USPS Web Tools User ID

Which server to use
test

Quote Sort Order
Price-LowToHigh

Handling Fee - US
0

Handling Fee - International
0

Handling Per Order or Per Box
Box

Decimal Settings
2

Tax Class
Taxable Goods

Tax Basis
Shipping

Shipping Zone
--none--

Sort Order
0

All Packages are Machinable?
False

USPS Options
Display weight, Display transit time

USPS Domestic Transit Time Calculation Mode
NEW

USPS Domestic minimum Length
8.625

USPS minimum Width
5.375

USPS minimum Height
1.625

USPS International minimum Length
9.50

USPS minimum Width
1.0

USPS minimum Height
5.50

Enable USPS First-Class filter for US shipping
True

Shipping Methods (Domestic and International)
First-Class Mail Letter, 0, .21875, 0.00, First-Class Mail Large Envelope, 0, .8125, 0.00, First-Class Package Service - RetailTM, 0, .8125, 0.00, First-ClassTM Package Service, 0, .9375, 0.00, 0, 70, 0.00, USPS Retail GroundRM, 0, 70, 0.00, Priority MailTM, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, Priority MailTM Small Flat Rate Box, 0, 70, 0.00, Priority MailTM Medium Flat Rate Box, 0, 70, 0.00, Priority MailTM Large Flat Rate Box, 0, 70, 0.00, 0, 15, 0.00, 0, 20, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, .21875, 0.00, 0, 4, 0.00, 0, 4, 0.00, 0, 66, 0.00, 0, 4, 0.00, 0, 4, 0.00, 0, 20, 0.00, 0, 20, 0.00, 0, 66, 0.00, 0, 4, 0.00, 0, 70, 0.00, 0, 70, 0.00

Extra Services (Domestic)
Certified MailRM, N, USPS TrackingTM Electronic, Y, USPS TrackingTM, Y, Insurance, Y, Priority Mail Express Insurance, Y, Priority Mail Insurance, Y, Adult Signature Restricted Delivery, N, Adult Signature Required, N, Registered MailTM, N, Collect on Delivery, N, Return Receipt, N, Certificate of Mailing (Form 3665), N, Certificate of Mailing (Form 3817), N, Signature ConfirmationTM Electronic, N, Signature ConfirmationTM, N, Priority Mail Express 1030 AM Delivery, N, Certified MailRM Restricted Delivery, N, Certified MailRM Adult Signature Required, N, Certified MailRM Adult Signature Restricted Delivery, N, Signature ConfirmationTM Restricted Delivery, N, Signature ConfirmationTM Electronic Restricted Delivery, N, Collect on Delivery Restricted Delivery, N, Registered MailTM Restricted Delivery, N, Insurance Restricted Delivery, N, Insurance Restricted Delivery (Priority Mail Express), N, Insurance Restricted Delivery (Priority Mail), N

Extra Services (International)
Registered Mail, N, Insurance, N, Return Receipt, N, Electronic USPS Delivery Confirmation International, N, Certificate of Mailing, N

Retail pricing or Online pricing?
Online

Debug Mode

5 Apr 2021, 6:40 PM
#45
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

Turn the USPS debug-mode on and retry the shipping request. It will be a large file. I'll send you my direct email address via PM (Private Message); send that debug file to me.

5 Apr 2021, 7:05 PM
#46
coastalpond avatar

coastalpond

New Zenner

Join Date:
Feb 2021
Location:
Georgia
Posts:
11
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

ok I missed a step I see, but still having problems. It seems I didn't go far enough in check out. But when I get to that point where I select the rate. Under the USPS mod I get 80040B1A - Authorization failure. Perhaps username and/or password is incorrect, So I double check the userID and is right. But there is no space for password. I thought in the latest version of the mod you didn't need a password.

5 Apr 2021, 7:08 PM
#47
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

Coastalpond:

ok I missed a step I see, but still having problems. It seems I didn't go far enough in check out. But when I get to that point where I select the rate. Under the USPS mod I get 80040B1A - Authorization failure. Perhaps username and/or password is incorrect, So I double check the userID and is right. But there is no space for password. I thought in the latest version of the mod you didn't need a password.
From this posting by Ajeh back in 2014: https://www.zen-cart.com/showthread.php?211885-USPS-quot-80040b1a-Authorization-failure-quot

Call USPS and have them enable your code for the Production Server ... they are open until 11:00pm EST if I am not mistaken ...

5 Apr 2021, 7:50 PM
#48
coastalpond avatar

coastalpond

New Zenner

Join Date:
Feb 2021
Location:
Georgia
Posts:
11
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

Did that; and it was switched, then this happens.

[05-Apr-2021 19:36:31 UTC] Request URI: /index.php?main_page=shopping_cart, IP address: 96.93.162.190
#1 sizeof() called at [/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_modules_shipping_estimator.php:102]
#2 require(/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_modules_shipping_estimator.php) called at [/home/coastalp/public_html/includes/modules/shipping_estimator.php:297]
#3 require(/home/coastalp/public_html/includes/modules/shipping_estimator.php) called at [/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_shopping_cart_default.php:197]
#4 require(/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_shopping_cart_default.php) called at [/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/common/tpl_main_page.php:251]
#5 require(/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/common/tpl_main_page.php) called at [/home/coastalp/public_html/index.php:94]
--> PHP Warning: sizeof(): Parameter must be an array or an object that implements Countable in /home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_modules_shipping_estimator.php on line 102.

[05-Apr-2021 19:36:31 UTC] Request URI: /index.php?main_page=shopping_cart, IP address: 96.93.162.190
#1 sizeof() called at [/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_modules_shipping_estimator.php:130]
#2 require(/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_modules_shipping_estimator.php) called at [/home/coastalp/public_html/includes/modules/shipping_estimator.php:297]
#3 require(/home/coastalp/public_html/includes/modules/shipping_estimator.php) called at [/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_shopping_cart_default.php:197]
#4 require(/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_shopping_cart_default.php) called at [/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/common/tpl_main_page.php:251]
#5 require(/home/coastalp/public_html/includes/templates/responsive_sheffield_blue/common/tpl_main_page.php) called at [/home/coastalp/public_html/index.php:94]
--> PHP Warning: sizeof(): Parameter must be an array or an object that implements Countable in /home/coastalp/public_html/includes/templates/responsive_sheffield_blue/templates/tpl_modules_shipping_estimator.php on line 130.

On the front end I got this message

We are unable to find a USPS shipping quote suitable for your mailing address and the shipping methods we typically use.
If you prefer to use USPS as your shipping method, please contact us for assistance.
(Please check that your Zip Code is entered correctly.

5 Apr 2021, 11:06 PM
#49
tedjmaines avatar

tedjmaines

New Zenner

Join Date:
Mar 2021
Location:
Campbell, Texas USA
Posts:
13
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

Using zen cart v1.5.7C, USPS 2020-09-24 K11. I know this is an old problem but this new module has different code. Problem: Always shows Media Mail option even when not in Media Category (5). Where do I place and what do I place to get only Media Category to show Media Mail in this new module???. Any mixture of non media should not show media mail option. Thanks.

6 Apr 2021, 11:28 AM
#50
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

tedjmaines:

Using zen cart v1.5.7C, USPS 2020-09-24 K11. I know this is an old problem but this new module has different code. Problem: Always shows Media Mail option even when not in Media Category (5). Where do I place and what do I place to get only Media Category to show Media Mail in this new module???. Any mixture of non media should not show media mail option. Thanks.
I don't understand the problem statement.

What is the "Media Category (5)"? Did you have this working on a previous USPS version? If so, could you point me to a thread where Ajeh identified how to do it?

If I know "how you did it before", I can point you to "how to do it again".

6 Apr 2021, 11:25 PM
#51
tedjmaines avatar

tedjmaines

New Zenner

Join Date:
Mar 2021
Location:
Campbell, Texas USA
Posts:
13
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

lat9:

I don't understand the problem statement.

What is the "Media Category (5)"? Did you have this working on a previous USPS version? If so, could you point me to a thread where Ajeh identified how to do it?

If I know "how you did it before", I can point you to "how to do it again".

I have never got it working. in previous edition v154 and beyond, we did flat rate. I would like to get this working. I read the other versions post but it does not work for v157c with K11. If someone got it to work in previous versions of USPS maybe they can let you know. The code I read before used a master category number for Media (mine is Master_id = 5) for loop but that did not work on my K11.

11 Apr 2021, 1:41 PM
#52
craftcorner avatar

craftcorner

New Zenner

Join Date:
Dec 2017
Location:
Anderson, IN
Posts:
44
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

So, we installed the new patch in order to switch the URL's to secrure as directed. Using ZC 1.5.7a and the 2020-09-24 K11 build from USPS. Am I missing a setting somewhere? First Class does not show up as an option even on the lightest shipments, and I'm losing orders based on only priority mail and express mail showing up. I've gone back and checked the USPS module, and really didn't change anything except the handling fee. I don't offer flat rate for anything, so the only options my customers have are First Class Package Service, Priority Mail, Express Mail, First Class International Package, Priority Mail International, and Express Mail International. Here are my settings in the USPS module:
USPS Version Date
2020-09-24 K11

Enable USPS Shipping
True

Full Name or Short Name
Long

Enter the USPS Web Tools User ID
XXXXXXXXXXXXX (changed from original for privacy)

Which server to use
production

Quote Sort Order
Price-LowToHigh

Handling Fee - US
2.5

Handling Fee - International
3

Handling Per Order or Per Box
Order

Decimal Settings
3

Tax Class
--none--

Tax Basis
Shipping

Shipping Zone
--none--

Sort Order
0

All Packages are Machinable?
False

USPS Options
--none--

USPS Domestic Transit Time Calculation Mode
NEW

USPS Domestic minimum Length
8.625

USPS minimum Width
5.375

USPS minimum Height
1.625

USPS International minimum Length
9.50

USPS minimum Width
1.0

USPS minimum Height
5.50

Enable USPS First-Class filter for US shipping
True

Shipping Methods (Domestic and International)
0, .21875, 0.00, 0, .8125, 0.00, First-Class Package Service - RetailTM, 0, .8125, 0.00, 0, .9375, 0.00, 0, 70, 0.00, 0, 70, 0.00, Priority MailTM, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, 15, 0.00, 0, 20, 0.00, Priority Mail ExpressTM, 0, 70, 0.00, 0, 70, 0.00, 0, 70, 0.00, 0, .21875, 0.00, 0, 4, 0.00, First-Class Package International ServiceTM, 0, 4, 0.00, Priority Mail InternationalRM, 0, 66, 0.00, 0, 4, 0.00, 0, 4, 0.00, 0, 20, 0.00, 0, 20, 0.00, Priority Mail Express InternationalTM, 0, 66, 0.00, 0, 4, 0.00, 0, 70, 0.00, 0, 70, 0.00

Extra Services (Domestic)
Certified MailRM, N, USPS TrackingTM Electronic, N, USPS TrackingTM, N, Insurance, N, Priority Mail Express Insurance, N, Priority Mail Insurance, N, Adult Signature Restricted Delivery, N, Adult Signature Required, N, Registered MailTM, N, Collect on Delivery, N, Return Receipt, N, Certificate of Mailing (Form 3665), N, Certificate of Mailing (Form 3817), N, Signature ConfirmationTM Electronic, N, Signature ConfirmationTM, N, Priority Mail Express 1030 AM Delivery, N, Certified MailRM Restricted Delivery, N, Certified MailRM Adult Signature Required, N, Certified MailRM Adult Signature Restricted Delivery, N, Signature ConfirmationTM Restricted Delivery, N, Signature ConfirmationTM Electronic Restricted Delivery, N, Collect on Delivery Restricted Delivery, N, Registered MailTM Restricted Delivery, N, Insurance Restricted Delivery, N, Insurance Restricted Delivery (Priority Mail Express), N, Insurance Restricted Delivery (Priority Mail), N

Extra Services (International)
Registered Mail, N, Insurance, N, Return Receipt, N, Electronic USPS Delivery Confirmation International, N, Certificate of Mailing, N

Retail pricing or Online pricing?
Online

Debug Mode
Off

11 Apr 2021, 3:28 PM
#53
craftcorner avatar

craftcorner

New Zenner

Join Date:
Dec 2017
Location:
Anderson, IN
Posts:
44
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

Never mind. It only had the first class - retail option selected; once I checked the first class - comm option, they started showing up again.

15 Apr 2021, 12:04 AM
#54
lrfowler24 avatar

lrfowler24

New Zenner

Join Date:
Feb 2010
Posts:
74
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

so......I have an item that is bulky...like 30" x 24" x 24"......around 30 pounds......BUT zencart chooses a large flat rate USPS box.......my item would never fit in a USPS LFR box!
how do I fix this problem?

15 Apr 2021, 11:44 AM
#55
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

lrfowler24:

so......I have an item that is bulky...like 30" x 24" x 24"......around 30 pounds......BUT zencart chooses a large flat rate USPS box.......my item would never fit in a USPS LFR box!
how do I fix this problem?
The USPS shipping module works on weights alone, so that 30-pound item will (from a weight standpoing) 'fit' in the large flat-rate box, which is limited to 70 pounds.

15 Apr 2021, 1:41 PM
#56
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

lrfowler24:

so......I have an item that is bulky...like 30" x 24" x 24"......around 30 pounds......BUT zencart chooses a large flat rate USPS box.......my item would never fit in a USPS LFR box!
how do I fix this problem?

You could change the max weight of a LFRbox from 70 down to something more realistic.

In our case & based upon the products we sell, we limit SMfr boxes to a total zencart weight of 1.5 pounds
Regional A boxes 1.51 to 3.00 pounds
MEDfr from 3.01-7 pounds

Then juggle database weights of products to make them fit to the boxes desired. Not perfect but works for us.

2 May 2021, 10:30 PM
#57
helenewallis avatar

helenewallis

Totally Zenned

Join Date:
Jun 2016
Location:
Suffolk VA
Posts:
625
Plugin Contributions:
0

Re: USPS Shipping Module [Support Thread]

i saw something in this forum about the Unsecure HTTP Endpoint Retirement, and there being a patch for that. I can't find it now, but when I got the USPS notice, I just searched the files for all the places where http://production.shippingapis dot com was mentioned, and changed them to https. Is anything needed besides that? I have the 2017 version of the file, if that makes any difference.

3 May 2021, 12:06 PM
#58
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

HeleneWallis:

i saw something in this forum about the Unsecure HTTP Endpoint Retirement, and there being a patch for that. I can't find it now, but when I got the USPS notice, I just searched the files for all the places where http://production.shippingapis dot com was mentioned, and changed them to https. Is anything needed besides that? I have the 2017 version of the file, if that makes any difference.
From the updated module's _getQuote method:

        // Prepare to make quote-request to USPS servers
        switch (MODULE_SHIPPING_USPS_SERVER) {
            // -----
            // 20200924 Update: USPS will be phasing out the http:// (non-secure) URL.
            //
            // Secure APIs: https://secure.shippingapis.com/ShippingAPI.dll
            // Non-secure APIs: http://production.shippingapis.com
            //
            case 'production':
                $usps_server = 'https://secure.shippingapis.com';
                $api_dll = 'ShippingAPI.dll';
                break;
            case 'test':
            default:
    // 09-7-2014
    //Secure APIs: https://stg-secure.shippingapis.com/ShippingApi.dll
    //Non-secure APIs: http://stg-production.shippingapis.com/ShippingApi.dll
                $usps_server = 'https://stg-secure.shippingapis.com';
                $api_dll = 'ShippingApi.dll';
                break;
        }
5 May 2021, 6:51 PM
#59
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

I've just submitted USPS version 2021-05-05 K11a for the Zen Cart moderators' review and will post back here when it's available for download.

 This release contains changes associated with the following GitHub issues:

#15: Correcting minimum International dimensions so that International Small F/R Box can be quoted.
#16: Add notification to enable site-specific customizations for configured shipping methods.

6 May 2021, 6:44 PM
#60
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,096
Plugin Contributions:
56

Re: USPS Shipping Module [Support Thread]

lat9:

I've just submitted USPS version 2021-05-05 K11a for the Zen Cart moderators' review and will post back here when it's available for download.

 This release contains changes associated with the following GitHub issues:

#15: Correcting minimum International dimensions so that International Small F/R Box can be quoted.
#16: Add notification to enable site-specific customizations for configured shipping methods.
Now available for download: https://www.zen-cart.com/downloads.php?do=file&id=1292