Jump to content
Latest News: (loading..)
torinwalker

New UPS XML Shipping Module available

Recommended Posts

There seems to be a number of errors in the latest version, most of which have a fairly simple fix (remove the REG symbols, etc.) However, IMHO posting fixes to this forum is the WORST possible way to go about doing things.

 

Torin: would it be too much trouble to actually amend the current version with the latest bug fixes as posted within this thread, call it v1.3, and upload it? I've noticed the same errors repeated here over and over - why not fix the problems in the SOURCE instead of relying on people to come here, post the question "Why am I receiving this error?" only to be told that THEY have to fix the bug themselves?

 

I'm sorry to gripe - it's a GREAT contribution, if only I could get it to work. Half of the "fixes" posted to this thread don't even tell exactly which file must be corrected.

 

[/soapbox]

Share this post


Link to post
Share on other sites

Also, that damned "Call-time pass-by-reference" error is showing up again, except it's not in the upsxml file, it's in the xmldocument.php file:

 

Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of [runtime function name](). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /web/sites/websolga/bikeherwear.com/catalog/admin/includes/classes/xmldocument.php on line 253

 

Also appearing on line 272 and 281 of the same file. :wacko:

 

What gives with that anyway?

Share this post


Link to post
Share on other sites

Hi, just tried running your mod on a MS2 shop, seems to run fine except I get a couple of warnings on the admin page. in packaging I see:

 

 

Warning: Failed opening 'includes/classes/htaccess.php' for inclusion (include_path='.:/php/includes:/usr/share/php') in /var/www/html/oscommerce/catalog/admin/packaging.php on line 59

 

at the top of the page,

 

and then when creating a new package, I see:

 

Warning: Missing argument 1 for shownewpackageform() in /var/www/html/oscommerce/catalog/admin/packaging.php on line 201

also at the top of the box.

 

How do I correct these problems...

Thanks

Dennis

Share this post


Link to post
Share on other sites

I am also receiving the following "warnings" when I try to update...

 

Warning: Missing argument 1 for showupdatepackageform() in /home/virtual/site3/fst/var/www/html/catalog/admin/packaging.php on line 231

 

How do I correct these situations...

 

Thanks In Advance...

Dennis

Share this post


Link to post
Share on other sites

has anyone seen this error from UPS ?

 

This module supports only xpci version 1.0001 of the UPS Tracking Interface. Please contact the webmaster for additional assistance.

 

that's found when a user clicks on "track".

Share this post


Link to post
Share on other sites

I downloaded the latest version and it works good so far. However, I did not install the dimension module. I tested couple of places and the price are correct if the dimension are within UPS spec. Otherwise, UPS will apply Dimensional Weight.

Share this post


Link to post
Share on other sites

This module is quit good, but it only works if the origin country is US because it sends an option that is only abailable for US. This option is the customerClasification, so if the origin country isn?t US you should not send to UPS this option. I have made this commenting out these 3 lines (near of line 595 in includes/modules/shipping/upsxml.php):

" <CustomerClassification>\n".

" <Code>". $this->customer_classification ."</Code>\n".

" </CustomerClassification>\n".

I hope this will be usefull.

Sorry abot my English.

Share this post


Link to post
Share on other sites

I have installed the latest version, and I'm having trouble with the packaging part of it. I have a product that is 108x2x2. We ship it in a box 108x6x4. This way we can ship 6 in a box for OSC 2 pricing. I can't get an accurate read from UPS on the price though. It is up to $60 cheaper in the shopping cart.

 

Does anyone have a soulution to take adaatage of the oversize package prices from UPS?

 

Also, I'm running into the same issue as someone posted earlier. The logic states 1 package if somone orders 7. There should be 2 packages.

 

Any help would be great, as I need to go live soon. Thanks in advance,

 

-Shawn

Edited by schizo

Share this post


Link to post
Share on other sites

I installed the 4 files as noted ; got my access key and can't it to work :(

 

I always get the same error :

 

Rating and Service 1.0001 0 An unknown error occured while attempting to contact the UPS gateway : Rating and Service 1.0001 0 An unknown error occured while attempting to contact the UPS gateway

 

I tried everything ; curl is installed etc...

I'm located in Belgium/Europe.

 

Also, how does one turn on the logging ? I removed the comment slashes but don't see the file getting created or writen to ?

 

THANKS!!

 

-Peter

Share this post


Link to post
Share on other sites

I'm not able to get it working either. I just get a blank page when I try to checkout. I think I've traced it working up until the

 

$xmlResponse = curl_exec($ch);

 

line. I'm getting an error from that. Is there anyway I can see what the error is from curl_exec()?

 

BTW, I never got the log file to work either, so I had error_log() send the log to my e-mail. You need to set the # in the second arg to 1 and then change the last arg from $this->logfile, to your email address in quotes. Then, anytime upsxml wants to write to the logfile, you'll get the messege in your e-mail. You will want to change this before you go live, it good for debugging.

Share this post


Link to post
Share on other sites

Hi.

 

I had it all working on my test server. It was working great!

 

I have moved all my files to my production server, refreshed the entire database and all the data, even removed and reinstalled the UPS XML module.

 

I am getting a blank screen when I attempt to checkout.

 

I did finally get the log to work, after chmod'ing the tmp directory to 777. This is the entire contents of the log file:

 

------------------------------------------

UPS URL: https://www.ups.com:443/ups.app/xml/Rate

 

 

There's nothing else in the log file. When I run it again, it appends exactly the same line.

 

I had the same difficulty with USPS Methods, but determined that there was a bug in the module attached to the "display transit time" option. When I unchecked the option, USPS Methods worked fine. I was rather hoping there would be something easy like that for the UPS XML module. Is there?

 

shris

:unsure:

Share this post


Link to post
Share on other sites

Never mind.

 

My production server doesn't show cURL support when I use the server info tool.

 

That may be the problem with the USPS module too, I'm not sure.

 

shris

Share this post


Link to post
Share on other sites

For Any One That Doesn't Have This Working.... and is getting the

 

Rating and Service 1.0001 0 An unknown error occured while attempting to contact the UPS gateway : Rating and Service 1.0001 0 An unknown error occured while attempting to contact the UPS gateway

 

Error....

 

 

 

 

I did have cURL enabled on my server and I've spent a lot of time debugging this damn thing.... and this is what you have to do to find out why its not working....

 

Find this line of code:

curl_setopt($ch, CURLOPT_TIMEOUT, (int)$timeout);

 

And add this after it:

curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
  curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);

 

 

Find this line of code:

error_log("UPS RESPONSE: " . $xmlResponse . "\n", 3, $this->logfile);

 

And change it to this:

error_log("Error Message: " . curl_error($ch) . "\nUPS RESPONSE: " . $xmlResponse . "\n", 3, $this->logfile);

 

$this->logfile needs to point to the complete UNIX filepath inorder to work...

IE: /home/yourwebspace/public_html/osc/tmp/logfile.log

 

If you still can't get logfile to work... change:

, 3, $this->logfile); (in the last change)

 

-to this-

, 1, 'me@you.com');  (replacing me@you.com with your email address)

 

This will allow you to see any error messages thrown by cURL as well as if you get any response from the UPS server.

 

I hope this helps most of you with problems, or at least figure out why you have these problems.

Share this post


Link to post
Share on other sites

Now I finally can connect with the UPS server I get UPS erros :(

 

e.g.:

 

111370: Unsupported Pickup Type

 

 

Anyone in EUROPE got this contrib up and running ????

 

 

Thx

 

-Peter

Share this post


Link to post
Share on other sites

can you please add comment (start & end) to the files you edited because I can't keep track which lines you modify when i have other contributions added. Especially the /admin/categories.php

 

Thank you

Share this post


Link to post
Share on other sites

forgot to add

it seems that /admin/categories.php is a bit different from Milestone 2.2MS2.

I'm so totally lost and i have to go compare every lines from the original one.

Share this post


Link to post
Share on other sites

Hi,

 

I've managed to add this contibution to my store with success.

(BTW: great job!! :D )

 

My company has an UPS account, how can I add that information to the XML request so I can get the calculation with the discount rate for that account?

 

Thanks in advance.

Share this post


Link to post
Share on other sites

Tools >BOX_TOOLS_PACKAGING this for me is FILENAME_PACKAGING was not found on this server. wich it isn't on my server . Is this only if you dload the UPS packaging module when you use thier packages ?

 

If so how do i make sure its disabled because I don't use thiers for used items . Makes them cost to much :)

 

Had to change a few things in the module to get it to work I forget now its been a week or so I forget what it was now. Found the fix in the forum thou. There was one other to .

Share this post


Link to post
Share on other sites

has anyone got this working osc ms2 i have this problem

 

111510: Unsupported packaging requested

 

i have read every post i can find on it cant seem to get it yet

 

thanks

Share this post


Link to post
Share on other sites
has anyone got this working osc ms2 i have this problem

 

111510: Unsupported packaging requested

 

i have read every post i can find on it cant seem to get it yet

 

thanks

I had that problem too. I'm not using the dimensions module. The problem was I had "Unknown Packaging" selected in the UPS XML Shipping Modules in the admin section. When I changed it to "Customer Packaging" it worked.

 

Hope that helps!


Scottie Wilcoxson (no advertising)

Share this post


Link to post
Share on other sites

I'm receiving rate quotes properly, but it appears that if i select a higher priced option (Ex, next-day air early am), that it loops back around to checkout_shipping. If i select the lowest priced item...then it works as it should.

 

Anyone else run into this?

Share this post


Link to post
Share on other sites

I had the same issue with the UPS XML module. After taking out

CODE

®

and

CODE

<sup>SM</sup>

from includes/languages/english/modules/shipping/upsxml.php it works fine.

 

For example change this line to:

 

CODE

define 'MODULE_SHIPPING_UPSXML_SERVICE_CODE_US_ORIGIN_12', 'UPS 3 Day Select®');

 

 

CODE

define 'MODULE_SHIPPING_UPSXML_SERVICE_CODE_US_ORIGIN_12', 'UPS 3 Day Select');

 

 

You should take out all the instances of ® and <sup>SM</sup>.

 

Hope this helps.

Share this post


Link to post
Share on other sites

Hi,

I seem to be having a weird problem with this module. I have installed it and it is working, but for some reason, when I go in the admin to Modules..Shipping, I get these two errors:

Warning: main(includes/modules/shipping/upsxml.php): failed to open stream: No such file or directory in /home/airlinem/public_html/catalog/includes/modules/shipping/ups.php on line 13

 

Fatal error: main(): Failed opening required 'includes/modules/shipping/upsxml.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/airlinem/public_html/catalog/includes/modules/shipping/ups.php on line 13

 

Then below that in the table it lists:

Flat Rate

Per Item

Table Rate

 

and nothing else.

I have verified that upsxml.php exists in the correct dir and has correct permissions. Why would it think it doesn't exist?

 

Any ideas?

Thanks

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

×