Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

UPS and USPS stopped working


Lavarock

Recommended Posts

I had all shipment modules working until I moved to another hosting site.

 

USPS and UPS are both returning errors, ZONE Rate is not. That tells me the weight is being retrieved.

 

-----

 

United Parcel Service

We are unable to obtain a rate quote for UPS shipping.

Please contact the store if no other alternative is shown.

 

United States Postal Service

An error occured with the USPS shipping calculations.

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

 

Zone Rates

Shipping to US : 6 lb(s) $10.50

 

-----

 

I enabled the "email" debug statement in both UPS and USPS and both reported an empty email for "$BODY" so it appears the $BODY is empty or non-printing characters.

 

I removed the USPS module and re added it and put my account info back in. I was using the production server and it worked on the other hosting service.

 

This hosting company (MYDOMAIN.COM) does not yet have CURL installed, but I don't think these use CURL and that they worked before without curl.

 

I have verified my ZIPCODE for my store and my country are correct.

 

After moving the code to the new host, I did change some text displays to ZIP CODE instead of POST CODE, but do not think any variables changed, just the text.

 

Any ideas? :huh:

Link to comment
Share on other sites

well, I about give up. I have copied many of the files over from my old system but still cannot get the shipping modules to work.

 

I'm not an expert in PHP, so I have not gotten some of the debug emails to display data.

 

I am guessing it may be the version of PHP on the new system or some thing turned off. I am days away from opening the store and will have to use flat shipping for now.

Link to comment
Share on other sites

Please help with this! Mine stopped working too and I feel as if I have tried everything.

 

It originally worked, then I tried to install UPS Choice and Fedex1 RTQuotes, couldn't get Fexdex to work, reinstalled my whole store and now they dont work! ack!

Link to comment
Share on other sites

Who is your host?

 

What are the error messages you see?

 

I have had problems with the shipping modules you refer to with my host, ipowerweb.com.

 

It has been hit or miss so I use a FedEx Zip Zones contrib instaed and it works well.

Link to comment
Share on other sites

I have tried putting debug statements all through the USPS.PHP file and think the problem may be about here...

 

This call appears to fail in my case.

 

if ($http->Connect($usps_server, 80)) {

$http->addHeader('Host', $usps_server);

$http->addHeader('User-Agent', 'osCommerce');

$http->addHeader('Connection', 'Close');

 

USPS_SERVER is "production.shippingapis.com"

Link to comment
Share on other sites

I forgot to mention that if I form a correct call to the production server using the data from these subroutines, i DO get a response back in my browser and the data looks correct (ie shipping rates, etc).

 

What I think is that this programmic USPS server connect is failing in the new server. Is there something in Apache or the PHP code that has to be enabled to make this type of programmic call?

Link to comment
Share on other sites

Following information in the thread http://www.oscommerce.com/forums/index.php?showtopic=93928

 

I edited \catalog\includes\modules\shipping\ups.php

 

I changed "

 

 

if ($http->Connect('www.ups.com', 80)) {

to

if ($http->Connect('153.2.228.50', 80)) {

 

and it seems I can get through now.

 

I tried the same trick for USPS but it does not seem to work at that site for their server address.

Edited by Lavarock
Link to comment
Share on other sites

Aha! I Figured it out. It was the UPS Choice Module that I had installed which gave me the same errors as Lava. ::

 

United Parcel Service

We are unable to obtain a rate quote for UPS shipping.

Please contact the store if no other alternative is shown.

 

United States Postal Service

An error occured with the USPS shipping calculations.

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

 

It turned out I was using the wrong version of ups.php for the modules. I downloaded the newest copy for ms2 and I am now again recieving quotes.

 

Only thing is, these quotes seem a little high. It is telling me $20 shipping for 40 lbs to ship in my own town. It should around $12 to ship to be realistic. Any ideas? :blink:

Link to comment
Share on other sites

Thanks for your help Lava! For the records, my problem with the overpriced shipping quotes was that I forgot to set my tare weights to zero. (Both small and large packages options). :P

Link to comment
Share on other sites

I'm also with iPowerWeb and have not had any luck with any of the shipping modules. I'm trying to get the UPS one to work but haven't had any luck. I get this error, "UPS Unsupported country specified". Any ideas?

Perform s search in the forums here. I think that message has been common.

Link to comment
Share on other sites

  • 4 months later...

I have continued to have problems getting USPS module to work.

 

I believe that I read about a PHP DNS lookup problem in earlier versions and perhaps many of us are on hosting companies that have not applied the fix.

 

I do know that I have been quite unsucessful getting MYDOMAIN.COM to add or fix any core programs, etc.

 

USPS does not seem to work if you hardcode the IP address in the code, possibly because both the test and production servers point to the same IP address 56.0.134.43.

 

Searched in Oscommerce forums for this error are difficult because words like IP and DNS and USPS seem to be blocked in searches.

Link to comment
Share on other sites

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