Jump to content



Latest News: (loading..)

- - - - -

USPS Rate V4, Intl Rate V2 (official support thread)


  • Please log in to reply
482 replies to this topic

#141   graveyardrecords

graveyardrecords
  • Members
  • 2 posts
  • Real Name:jeff

Posted 07 April 2012 - 10:29 PM

@fulluvscents thanks for this contrib, but I'm having a problem still.

on the page: /checkout_shipping.php

I get the following error:
This is currently the only shipping method available to use on this order.

I followed your directions but no idea why I'm not getting anything from USPS.

I'm using OSC 2.2RC2a
with php v 5.2.17

so currently no one can buy anything on the website until this issue is fixed, actually the above error I received prior to installing your contrib. I installed yours hoping it would fix the problem. Any other ideas what might cause it?

jeff

#142   jhaugen

jhaugen
  • Members
  • 24 posts
  • Real Name:Jerry Haugen

Posted 09 April 2012 - 06:08 AM

Hi @fulluvscents.

I downloaded and installed USPS Rates V4 yesterday, on a fairly clean osc 2.3.1 install.  I see the USPS rates from this contribution, the UPS rates from 'UPS XML Rates' and a flat rate, that I haven't turned off yet.  When I go to pay with the  Paypal express that comes with 2.3.1 I get:
Fatal error: Class 'httpClient' not found in . . .  /includes/modules/shipping/usps.php on line 287
Even if I use some other shipping method.

Kinda looks like the class didn't get included in usps.php, but it seems like you would have picked that up long ago.  Any Ideas?

-Jerry-

#143   MattKopec

MattKopec
  • Members
  • 13 posts
  • Real Name:Matt Kopec

Posted 09 April 2012 - 05:22 PM

Installed the USPS shipping mod for v2.2 ( http://addons.oscommerce.com/info/8403) and now my site is broken, I'm getting a blank white screen! The backend still functions but the store is down.

Can anyone please help.

Thanks

#144   fulluvscents

fulluvscents
  • Members
  • 305 posts
  • Real Name:Jetta
  • Gender:Female
  • Location:Fort Wayne, Indiana

Posted 11 April 2012 - 05:47 AM

@jhaugen

Actually, I hadn't run into it until this very evening while testing something else out with PayPal express.  It's a simple fix:

Find:

$http = new httpClient();

Add this before it:

if (!class_exists('httpClient')) include('includes/classes/http_client.php');

@MattKopec

Are your php errors turned on?  Is this specific to one page or another, or is it sitewide?

#145   fulluvscents

fulluvscents
  • Members
  • 305 posts
  • Real Name:Jetta
  • Gender:Female
  • Location:Fort Wayne, Indiana

Posted 11 April 2012 - 10:17 AM

@MattKopec

In the usps.php file, add this:

error_reporting(E_ALL);

right before:
class usps

Run through the checkout and grab the error you're getting.

Then remove the snippet back out of the file, turn the mod off, and post back here with the error.

#146   EdLee

EdLee
  • Members
  • 3 posts

Posted 11 April 2012 - 10:40 PM

Wow Jetta this sure is a hot topic!  I installed the mod and got my usps account activated.

I still get the message "An error occured with the USPS shipping calculations.
If you prefer to use USPS as your shipping method, please contact the store owner."

In your mod you say to dsable the usps module in the admin tool before file modification... which I did.

After I edited files I reenabled the usps module... is that a mistake to do so?

I went through the php on the shipping module to make sure it was still sending (doesn't get edited in the mod)
and it is sending to the right address which is        http://production.shippingapis.com/ShippingAPI.dll
       https://secure.shippingapis.com/ShippingAPI.dll

I appreciate your insight on this matter.

Thanks so much!

#147   fulluvscents

fulluvscents
  • Members
  • 305 posts
  • Real Name:Jetta
  • Gender:Female
  • Location:Fort Wayne, Indiana

Posted 12 April 2012 - 12:52 AM

Quote

An error occured with the USPS shipping calculations.
If you prefer to use USPS as your shipping method, please contact the store owner.

Are you sure you're not using the USPS Methods contribution?  It's not the same as this one.  This one doesn't display errors.  Errors are silent.

In any regard, there is a line that will email you the USPS response.  You can un-comment that line, and first find out what response you're getting, before doing anything else to debug.

#148   jhaugen

jhaugen
  • Members
  • 24 posts
  • Real Name:Jerry Haugen

Posted 12 April 2012 - 12:52 AM

Thanks Jetta,  that resolved my PayPal issue.  I appreciate your efforts with this and other pieces of osC.

-Jerry-

#149   fulluvscents

fulluvscents
  • Members
  • 305 posts
  • Real Name:Jetta
  • Gender:Female
  • Location:Fort Wayne, Indiana

Posted 12 April 2012 - 05:22 AM

Attached is an alternative script which MAY work for those on pre-php 5.2.  It is not fully tested, but is worth a shot.  Feedback is appreciated.

Attached Files

  • Attached File  usps.php   21.26K   18 downloads

Edited by fulluvscents, 12 April 2012 - 05:22 AM.


#150   GoTTi

GoTTi
  • Members
  • 448 posts
  • Real Name:GoTTi

Posted 17 April 2012 - 07:14 AM

hi just started to have this error tonight after doing some test checkouts that were working....

when i click to checkout, the page just loads then refreshes with no pricing for shipping. at the top of the checkout_shipping.php page it shows:

Warning: fsockopen() [function.fsockopen]: unable to connect to production.shippingapis.com:80 (Connection timed out) in /home/SITE/public_html/includes/classes/http_client.php on line 330

and it says

Shipping Method
This is currently the only shipping method available to use on this order.




but nothing is there....is the usps server down for maintenance or something? does this happen often? thanks

#151   creepo

creepo
  • Members
  • 41 posts
  • Real Name:Jim
  • Gender:Male
  • Location:IN, USA

Posted 17 April 2012 - 11:25 AM

Same here.  production.shippingapis.com is down.  Since about 1:40 CST.  Haven't been able to find anyone else talking about it.  Anyone?  Echo?

I'm turning off USPS for now.  Argh.

J

View PostGoTTi, on 17 April 2012 - 07:14 AM, said:

hi just started to have this error tonight after doing some test checkouts that were working....

when i click to checkout, the page just loads then refreshes with no pricing for shipping. at the top of the checkout_shipping.php page it shows:

Warning: fsockopen() [function.fsockopen]: unable to connect to production.shippingapis.com:80 (Connection timed out) in /home/SITE/public_html/includes/classes/http_client.php on line 330

and it says

Shipping Method
This is currently the only shipping method available to use on this order.




but nothing is there....is the usps server down for maintenance or something? does this happen often? thanks


#152 ONLINE   altoid

altoid
  • Community Sponsor
  • 761 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Hollidaysburg, Pennsylvania

Posted 17 April 2012 - 12:02 PM

0800 EDST here, just ran a test order.   The module worked correctly for me.
I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC.  It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce.  Look around, you'll figure out who they are.

#153   GoTTi

GoTTi
  • Members
  • 448 posts
  • Real Name:GoTTi

Posted 17 April 2012 - 10:42 PM

ya its back online now. no issues

#154   russellh9

russellh9
  • Members
  • 18 posts
  • Real Name:Russ Haskell
  • Location:ohio

Posted 19 April 2012 - 06:44 PM

Hi
I'm running an older version of osCommerce v2.2 and have installed the Ratev4 application with the new usps files and I've modified the two admin files as well as added the addition to the application_top file. I get all the rates and everything in the back end in the usps shipping module but when I go to check out the USPS shipping choices don't show up in checkout. I uncommented the email line in usps.php so that I would receive any debug messages. Here's what I keep getting:

<?xml version="1.0"?>
<Error><Number>-2147219085</Number><Source>Rate_Respond.;SOLServerRates.RateV4_Respond</Source><Description>Invalid XML Element content is incomplete according to the DTD/Schema.
line= 0 pos= 1668</Description><HelpFile></HelpFile><HelpContext>1000440</HelpContext></Error>


What can the problem be??

I appeciate any help Jetta or anyone who has solved this problem can give me.

Thanks!

Russ

#155   russellh9

russellh9
  • Members
  • 18 posts
  • Real Name:Russ Haskell
  • Location:ohio

Posted 19 April 2012 - 06:46 PM

By the way, I upgraded PHP to version 5 on my server.

#156   russellh9

russellh9
  • Members
  • 18 posts
  • Real Name:Russ Haskell
  • Location:ohio

Posted 19 April 2012 - 07:50 PM

Well, if I only had a brain!! Problem fixed! I forgot to choose a USPS shipping method in the backend module section. Works fine now.

#157   russellh9

russellh9
  • Members
  • 18 posts
  • Real Name:Russ Haskell
  • Location:ohio

Posted 20 April 2012 - 11:47 PM

I installed the files on one site and all works perfectly. I installed on an osCommerce 2.2 on another server and all works ok EXCEPT that the shipping amount does not carry over into the payment screen. It shows up ok after customer login ( we are using just USPS priority mail with delivery confirmation ) but once the payment details are entered and you click procede, the shipping disappears from the shopping cart. What can the problem be? I uninstalled the USPS module, deleted all of the files, reinstalled the files again and re-enabled the USPS module in admin. All looks good in admin except shipping disappears in the payment page. PLEASE HELP! This is driving me crazy:)

#158   russellh9

russellh9
  • Members
  • 18 posts
  • Real Name:Russ Haskell
  • Location:ohio

Posted 21 April 2012 - 12:25 AM

Hi Jetta

  As to the problem posted above ( shipping pricing not showing up in shopping cart after entering payment information ) I did a test order and received an email receipt. In the receipt I was charged the shipping price that showed after I added the item to my shopping cart. So even though USPS shipping does not show up in checkout after choosing a payment option and entering payment data, it actually charges the correct amount to the purchaser. Strange! Shipping shows up before payment, disappears on payment checkout and appears in the customer receipt email! Totally confused about this. Have you run into this problem before? Thanks for your help!

#159   russellh9

russellh9
  • Members
  • 18 posts
  • Real Name:Russ Haskell
  • Location:ohio

Posted 21 April 2012 - 12:37 AM

UPDATE TO ABOVE PROBLEM. Now it works?? Gremlins abound in the osCommerce universe:) Must be a conspiracy to drive me mad ;)

#160   fulluvscents

fulluvscents
  • Members
  • 305 posts
  • Real Name:Jetta
  • Gender:Female
  • Location:Fort Wayne, Indiana

Posted 21 April 2012 - 05:58 AM

haha.  Sorry, I wasn't of much help, but it looks like you've got it resolved?  My first thought - turn on shipping in the order total modules.