Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Fedex module not returning rates...


zakooldude

Recommended Posts

When I try to checkout (I am using fedex module), I get this error:

 

No Rates Returned, F01C : Recipient postal code and state/province do not match.

 

There is nothing wrong with the zipcodes matching the states.. I've tried several valid zipcode/state combinations in different states to no avail.

 

I am wondering if something has gone wrong in my OSC system. Can someone please guide me on this one, I am really stuck....

 

TIA

Link to comment
Share on other sites

The debug error:

 

Data sent to Fedex for Rating: 0,"25"10,"285988624"498,"3442207"8,"CA"9,"94544"117,"US"17,"94587"50,"US"75,"LBS"1116,"I"1401,"3.5"1529,"1"1415,"9.00"68,"USD"440,"N"1273,"01"1333,"1"99,""

Data returned from Fedex for Rating: 0,"125"2,"F01C"3,"Recipient postal code and state/province do not match."99,""

Link to comment
Share on other sites

  • 2 weeks later...

Although I know FedEx did change their API, it has not solved the problem for me. I'm still getting the "F01C" error after removing the module and installing the new one. Any ideas?

Link to comment
Share on other sites

  • 2 weeks later...

Sure, turn on debug so you can make sure what data you are sending. If a foreign shipment, there is nothing that can be done until Fedex make another software change. Otherwise, have hundreds of people using the module just fine, including me! So, turn on debug.

Steve

Link to comment
Share on other sites

  • 2 weeks later...

Here's how it went for me: Fedex "corrected" themselves so that state codes were required for rate quotes, as per their existing documentation. It caused so many problems they say they've rolled it back. The fact of the matter is many International countries still require state/province codes - they did not roll back the international state requirement. I had installed the most recent fedex contribution that was supposed to fix the problem when they first required state codes - here's how I've edited it so that I get rates back on any address:

 

********************

 

#Malaga 030404 because Fedex requires state code in many many countries

#old:

#if (MODULE_SHIPPING_FEDEX1_STATE != 'NONE') {

#$data .= '4012,"' . MODULE_SHIPPING_FEDEX1_STATE . '"'; // Subscriber State code

#}

#new:

$data .= '4012,"' . MODULE_SHIPPING_FEDEX1_STATE . '"'; // Subscriber State code

#end new

 

 

********************

 

#Malaga 030404 because fedex requires state code

#added:

if (MODULE_SHIPPING_FEDEX1_STATE == "NONE" || strlen(MODULE_SHIPPING_FEDEX1_STATE) == 0) {

return array('error' => 'You forgot to set up your ship from State or Province, this can be set up in Admin -> Modules -> Shipping');

}

#end added

 

 

**********************

 

#Malaga 030404 because fedex requires state code all over the place

 

 

#if ($order->delivery['country']['iso_code_2'] == "US" || $order->delivery['country']['iso_code_2'] == "CA" || $order->delivery['country']['iso_code_2'] == "PR") {

# $dest_zip = str_replace(array(' ', '-'), '', $order->delivery['postcode']);

# $data .= '17,"' . $dest_zip . '"'; // Recipient zip code

# $data .= '16,"' . tep_get_zone_code($order->delivery['country']['id'], $order->delivery['zone_id'], '') . '"'; // Recipient state

#}

 

#new:

$dest_zip = str_replace(array(' ', '-'), '', $order->delivery['postcode']);

$data .= '17,"' . $dest_zip . '"'; // Recipient zip code

$data .= '16,"' . tep_get_zone_code($order->delivery['country']['id'], $order->delivery['zone_id'], '') . '"'; // Recipient state

#end new

Malaga Smith

Link to comment
Share on other sites

That's great, and works in some cases, but far from all. You see, you still have to have the state code Fedex is expecting. One simple example is QC is NOT Quebec in Canada according to Fedex, while most any Canadian user would type QC. So, it is much more complicated than just putting in state codes as your change does here. This type of discrepancy exists in numerous countries all over the world. So, your change would fix some percentage of them, but far from all.

 

The only solution is going to be when they remove the state requirement. Until then, it's not really feasible to attempt to translate all state codes worldwide. Nor is it reasonable. They need to fix their code!

 

I am not aware that they have indeed removed any state code required as of yet, they SAY they are going to, but I have not been informed at least of that change.

Steve

Link to comment
Share on other sites

  • 3 weeks later...

According to Fedex they've completely rolled back the state code requirement. Anyway, this fix worked in our case, and just thought I'd share as it was a time consuming issue.

Malaga Smith

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...