Jump to content
Sign in to follow this  
spoot

Automated FedEx Labels

Recommended Posts

Hi all,

This looks like a great contrib, but I seem to be having problems connecting to the test server. I looked through all 15 pages, but no one else has posted this error. When I click submit on the ship page I get the following error:

 

ERROR: cURL ERROR: 6: name lookup timed out

 

Both fedexdc's have test as the server, and I've been using the fedex realtime quote contrib without a problem. Any ideas?

Share this post


Link to post
Share on other sites
Hi all,

  This looks like a great contrib, but I seem to be having problems connecting to the test server.  I looked through all 15 pages, but no one else has posted this error.  When I click submit on the ship page I get the following error:

 

ERROR: cURL ERROR: 6: name lookup timed out

 

Both fedexdc's have test as the server, and I've been using the fedex realtime quote contrib without a problem.  Any ideas?

 

 

try turning this number up on the top of fedexdc.php

 

define('REQUEST_TIMEOUT', 10, true);

Share this post


Link to post
Share on other sites
try turning this number up on the top of fedexdc.php

 

define('REQUEST_TIMEOUT', 10, true);

 

Ah, when I read your response I almost smacked myself in the face. That probably should have been the first thing to try.... and it worked. Thanks for the help yeahyeah :thumbsup:

Share this post


Link to post
Share on other sites

yeahyeah, did you ever get the problem with the 0 size png files being sent figured out? I have the same problem :rolleyes:

Edited by AverageJoe

Share this post


Link to post
Share on other sites

Ok, this is strange. When I make a label for a 1 box shipment, I get a broken link (and a 0 byte png file shows up in the fedex images folder). If I make a label for a 2 box shipment, the first is a broken link but the second label works correctly.

 

Anyone have any ideas?

Share this post


Link to post
Share on other sites

Yeah..I have this problem in the test system too. But it works well in production. I find it strange too.

 

By the way, I just heard that FedEx.com will be down for servicing from July 9th (Sat) 14:00 CST - 10th (Sun) 08:00 CST. For those of you relying on FedEx quotes to give shipping rates, you might want to have alternatives shipping method. :)


- The Jackal

Share this post


Link to post
Share on other sites
yeahyeah, did you ever get the problem with the 0 size png files being sent figured out?  I have the same problem  :rolleyes:

 

comment this line out.

//                if (empty($match[1])) continue;

Share this post


Link to post
Share on other sites
comment this line out.

// ? ? ? ? ? ? ? ?if (empty($match[1])) continue;

 

Thanks for the reply... you seem to be saving my ass when it comes to this contribution :blush:

 

Last question: I'm getting the labels, but it's coming up with

TEST LABEL CONTACT,

TEST LABEL COMPANY,

TEST LABEL ADDRESS,

TEST LABEL CITY, MA 02132

 

I take it because I'm on the test server and not production. Will this work correctly once I switch it over? (from what TheJackel says it looks good)

 

Thanks again for all the help :thumbsup:

Share this post


Link to post
Share on other sites

anybody? ideas?

I would greatly appreciate it! I installed the latest version of this contrib.

 

ship_fedex.php

 

Warning: fopen(DIR_WS_FEDEX_LABELS343828910000260.png): failed to open stream: Permission denied in /home/virtual/site/var/www/html/catalog/admin/includes/fedexdc.php on line 251

 

Warning: fwrite(): supplied argument is not a valid stream resource in /home/virtual/site/var/www/html/catalog/admin/includes/fedexdc.php on line 252

 

Warning: Cannot modify header information - headers already sent by (output started at /home/virtual/site/var/www/html/catalog/admin/includes/fedexdc.php:251) in /home/virtual/site/var/www/html/catalog/admin/includes/functions/general.php on line 18

 

Thank you!

Share this post


Link to post
Share on other sites

Well, the first error sounds like you didn't chmod the fedex image folder to 777. As for the others, I'm not accustomed to the program yet to know :rolleyes:

Share this post


Link to post
Share on other sites
anybody? ideas?

I would greatly appreciate it!  I installed the latest version of this contrib.

 

ship_fedex.php

 

Warning: fopen(DIR_WS_FEDEX_LABELS343828910000260.png): failed to open stream: Permission denied in /home/virtual/site/var/www/html/catalog/admin/includes/fedexdc.php on line 251

 

Warning: fwrite(): supplied argument is not a valid stream resource in /home/virtual/site/var/www/html/catalog/admin/includes/fedexdc.php on line 252

 

Warning: Cannot modify header information - headers already sent by (output started at /home/virtual/site/var/www/html/catalog/admin/includes/fedexdc.php:251) in /home/virtual/site/var/www/html/catalog/admin/includes/functions/general.php on line 18

 

Thank you!

 

first error: see the first few pages of this thread. you're missing a line in filenames.php

fwrite error: try using a full path instead of relative on the fwrite line e.g. /usr/local/htdocs/mystore.com/catalog/admin/images/fedex/post.txt

Share this post


Link to post
Share on other sites

yeahyeahyeah, Thank you!

 

It was just 1 line (and it solved all 3 errors), but in catalog/admin/includes/configure.php, not filenames.php.

define('DIR_WS_FEDEX_LABELS', DIR_WS_IMAGES . 'fedex/');

 

 

Now I have the same problem many others seem to have. When trying to process 1 package, I just get a broken image. When I process 2 packages, the first one is a broken image, the second one shows up... hmm.

Share this post


Link to post
Share on other sites
Now I have the same problem many others seem to have.?  When trying to process 1 package, I just get a broken image. When I process 2 packages, the first one is a broken image, the second one shows up... hmm.

 

I think it's just because we're using the test server. Try the fix yeahyeahyeah posted further up and you'll see that you are getting information back from fedex, it's just generic test infomation. Don't know why labels for a 2nd box wouldn't get the test information too, but I'm chaulking that up to fedex.

Edited by AverageJoe

Share this post


Link to post
Share on other sites

RE: Broken Image Error.

 

I to now am experiencing this broken image error. I have all the latest updates. I've been running Fedex Labels for months now, and all of a sudden today I get broken png images. I am on the Production Server and have been for months. I have made absolutely NO changes to any of my files in weeks and it was working perfectly until today. I last successfully printed labels on Thursday evening.

 

I can tell you this: It is not a browser problem, because when I go into my saved Fedex label files and export the png file (the fedex label) and then try to open it with Adobe Photoshop, it is a blank image....nothing on it. Also, if I go to display my old Fedex Labels, they do display WITHOUT problems.

 

Soooo, Fedex must have changed something in the last few days that has created a communication problem in the Fedex Automated Labels mod.

 

Please help!!!

Share this post


Link to post
Share on other sites

I just finished installing and debugging 1.07

 

I already have a working fedex realtime quotes install. I currently do labels online from fedex.com so that part works. However, when I try and generate a label from the contrib I get the following:

 

 

>>This transaction could not be completed. Please note the error message below.

 

>>ERROR: FedEx Return Error 0911 : Resources are unavailable to service your >>request.

 

Anyone have any ideas on this? Seems like a fed ex problem.

Share this post


Link to post
Share on other sites
RE: Broken Image Error.

 

I to now am experiencing this broken image error.  I have all the latest updates.  I've been running Fedex Labels for months now, and all of a sudden today I get broken png images.  I am on the Production Server and have been for months.  I have made absolutely NO changes to any of my files in weeks and it was working perfectly until today.  I last successfully printed labels on Thursday evening.

 

I can tell you this:  It is not a browser problem, because when I go into my saved Fedex label files and export the png file (the fedex label) and then try to open it with Adobe Photoshop, it is a blank image....nothing on it.  Also, if I go to display my old Fedex Labels, they do display WITHOUT problems.

 

Soooo, Fedex must have changed something in the last few days that has created a communication problem in the Fedex Automated Labels mod.

 

Please help!!!

 

Exact same issue here. I'm just hoping that nothing too complicated has changed on FedEx' end since this contrib is as simple as it can get without major points of failure. I'll try to get a hold of the dev guys at fedex in the morning to see what's going on as we kind of depend on it being up. (It would be nice if something was posted or sent ou to their users though)

Share this post


Link to post
Share on other sites

Yup, Fedex labels image broke here too, no changes to my site in six months, working fine until the past 2 days. IE or Firefox, no matter.

Fedex, what did you do? :blink:


--Jeff

Of course I don't look busy! I did it right the first time!

Share this post


Link to post
Share on other sites
Yup, Fedex labels image broke here too, no changes to my site in six months, working fine until the past 2 days. IE or Firefox, no matter.

Fedex, what did you do?  :blink:

 

Ditto


Most Valuable OsCommerce Contributions:

Also Purchased (AP) Preselection (cuts this resource hogging query down to nothing) -- Contribution 3294

FedEx Automated Labels -- Contribution 2244

RMA Returns system -- Contribution 1136

Sort Products By Dropdown -- Contribution 4312

Ultimate SEO URLs -- Contribution 2823

Credit Class & Gift Voucher -- Contribution 282

Cross-Sell -- Contribution 5347

Share this post


Link to post
Share on other sites

Still on the phone with the FedEx dev team and the only changes made over the weekend (which could possibly affect us) is the addition of "Signature services". I do not see how this can affect the label priting part, but we're both working on a solution as we speak.

 

While I'm at it, signature services sounds like a welcome addition so it might as well be added. Depending on my time, I might report back with a solution and maybe even a sig. addon.

Share this post


Link to post
Share on other sites

Hi All,

 

I have the same problem and I tried using YeahYeahYeah solution for the test system and it works on production too.

 

In Admin/Includes/fedexdc.php, just comment out

 

//                if (empty($match[1])) continue;

 

It works for me. Thanks YeahYeahYeah for the life saver!


- The Jackal

Share this post


Link to post
Share on other sites
Still on the phone with the FedEx dev team and the only changes made over the weekend (which could possibly affect us) is the addition of "Signature services". I do not see how this can affect the label priting part, but we're both working on a solution as we speak.

 

While I'm at it, signature services sounds like a welcome addition so it might as well be added. Depending on my time, I might report back with a solution and maybe even a sig. addon.

 

Ok, so Im' getting a little ahead of myself here; the signature part as previously mentioned in posts by spoot are a simple addon (tag id 1208 I think it was). But how this affects label generation is still unknown. Anyone?

Share this post


Link to post
Share on other sites

Ok.... finally getting somewhere. Again, not sure how this will affect label printing, but some big changes where made to some of the field tags.

 

New field tags:

 

2399 (in regards to signatures)

 

0 = non specified

2 = indirect signature permitted

3 = direct signature required

4 = adult signature required

 

 

2402 = signature surcharge

 

2403 = listing of surcharge/gop surcharge

 

 

The first one (2399) is the biggest one that we have to pay attention to. We're in the process of updating ship_fedex.php to add the boxes/array, but at least one value should be posted to FedEx from what I understand. E.g. if you do not need a signature, you need to post 0 and so on.... That's where the problem is (I think).

 

Hope this helps you guys out there.

Share this post


Link to post
Share on other sites
Ok.... finally getting somewhere. Again, not sure how this will affect label printing, but some big changes where made to some of the field tags.

 

New field tags:

 

2399 (in regards to signatures)

 

0 = non specified

2 = indirect signature permitted

3 = direct signature required

4 = adult signature required

2402 = signature surcharge

 

2403 = listing of surcharge/gop surcharge

The first one (2399) is the biggest one that we have to pay attention to. We're in the process of updating ship_fedex.php to add the boxes/array, but at least one value should be posted to FedEx from what I understand. E.g. if you do not need a signature, you need to post 0 and so on.... That's where the problem is (I think).

 

Hope this helps you guys out there.

 

 

Around line 126

find

        0=>     $transaction_code // transaction code

add

      ,2399=> $HTTP_POST_VARS['signature_type'] // signature type

 

 

Add your arrays around line 505:

 

// arrays for signature services
               $signature_type = array();
               $signature_type[] = array('id' => '0', 'text' => 'None Required');
               $signature_type[] = array('id' => '2', 'text' => 'Anyone can sign');
               $signature_type[] = array('id' => '3', 'text' => 'Signature Required');
               $signature_type[] = array('id' => '4', 'text' => 'Adult Signature');

 

 

Around line 700 add drop down box:

          <tr>
                       <td class="main" align="right">Signature Options</td>
                      <td class="main"> </td>
                      <td class="main"><?php echo tep_draw_pull_down_menu('signature_type',$signature_type); ?></td>
        </tr>

 

Around line 820 add the hidden text field for signatures

 

<input type="hidden" name="signature_type" value="<?php echo $HTTP_POST_VARS['signature_type']; ?>" />

 

I think that's it. This is on the latest ship_fedex.php file. Some other failover changes were made not related to this change, just an external call to our local servers to be able to generate labels regardless if this is down or not; either way,the above should give you a head start.

Share this post


Link to post
Share on other sites

CDI-BUY and others who wanted the sign on delivery options created with the labels:

 

Simply add those changes I've posted a couple of posts above. All seems to go well as since my last post we've had 44 packages successfully accepted and shipped through FedEx :)

 

That new addition gives you the option to select those 4 types of signature options:

 

0 = no signature required (select for none)

2 = Can be signed by anyone

3 = Can ONLY be signed by the recipient (on the label)

4 = Requires adult signature.

 

These options (if you follow those installation instructions) will give you a drop down box etc with the specified signature code on the printed label.

 

Don't use it blindly, as there is a small surcharge ($0.90 for us, might be more or less for you) per signature option (except 0). These rates can be negotiated with your Fedex sales person if need be.

 

Perfect for eBay or wherever sigs are required for the different options.

 

 

All is well now plus that little addition. If anyone cares to package it in the next release, feel free to do so.

 

I hope that helps anyone.

 

Over and out.

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
Sign in to follow this  

×