Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

New UPS XML Shipping Module available


Recommended Posts

What is the service codes for the Scandinavian countries, Sweden, Norway, Denmark and Finland?

We would like to add them unless you have not made any update with these countries included.

 

 

// European Union Origin

'European Union Origin' => array(

'07' => MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_07,

'11' => MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_11,

'54' => MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_54,

'65' => MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_65

 

Thanks in advance

Link to comment
Share on other sites

Well, we have customers around the hole world but most of them are based within EU and we give prices in both EURO, SEK and USD.

I never tested this but when UPS returns a rate in SEK I assume the osC code translates that to other currencies. If your default currency for your prices is in euros this might explain the high price?

We tried both with and without comma and with and without points.

Nothing happend.

I don't understand what you are trying to do here.

 

About only quoting UPS Saver, we use more than UPS Saver so I wonder where did you get that information about that we are only using that kind of shipping here in Sweden?

I think you don't understand me. The UPSXML module shows all the rates UPS returns as quotes (unless you chose in the admin not to show certain kinds of shipping). I only tried to say that you shouldn't think something is wrong because you only get UPS Saver as shipping option because I believe it is the most common one for Europe.

About Curl, our website are based at a web hotel using a Apache MySQL webbserver with MySQL klientversion: 5.0.67.

That does't tell me if curl is enabled on that server. It is a PHP module and not all webserver need to be configured with all the PHP modules that are available.

I assume you tried this with different products and different destinations? If the quote changes I presume curl is working. In previous posts and in the readme.txt is explained how to log the request sent to UPS and log the answer the UPS server returns. If there is no answer curl is probably not working.

Link to comment
Share on other sites

What is the service codes for the Scandinavian countries, Sweden, Norway, Denmark and Finland?

We would like to add them unless you have not made any update with these countries included.

 

 

// European Union Origin

'European Union Origin' => array(

'07' => MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_07,

'11' => MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_11,

'54' => MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_54,

'65' => MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_65

The UPS documentation I have only uses 6 origins: US, EU, Canada, Puerto Rico, Mexico, and other origins. There is none for Scandinavian countries. The only difference between EU origin and Other origins is that EU origin has one more shipping option: UPS Standard (dec. 2006 documentation).

Link to comment
Share on other sites

Member states of the EU:

 

Austria

Belgium

Bulgaria

Cyprus

Czech Republic

Denmark

Estonia

Finland

France

Germany

Greece

Hungary

Ireland

Italy

Latvia

Lithuania

Luxembourg

Malta

Netherlands

Poland

Portugal

Romania

Slovakia

Slovenia

Spain

Sweden

United Kingdom

Link to comment
Share on other sites

Hi Jan,

 

Sorry to be a bother-- I can see you're in the middle of answering a bunch of other questions. The problem I was having was curl-related. My webhost recompiled curl with ssl and that got everything up and running, but with a dimensions error. Went through to make sure that all the dimensions instructions were followed, but I am getting a mysql error on my shopping cart box and shopping_cart.php page:

 

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/jennbaca/public_html/shop/includes/functions/database.php on line 99

 

It is referring to this bit of code in database.php:

 

  function tep_db_fetch_array($db_query) {
   return mysql_fetch_array($db_query, MYSQL_ASSOC);

 

I'm not sure how anything in the module would have changed this in any way. I'm thinking my best bet is to revert the shop and database back to before I installed the module and just start a fresh install. Do you know why this error might be coming up?

 

Thanks.

Link to comment
Share on other sites

Hello again Jan,

 

Which UPS XML documentation are you actual talking about. I am trying to find it through our online account at UPS.

 

I guess you have to make a change about the EU member states.

 

I will myself if you will give me details about your documents ask UPS about it. :D

Link to comment
Share on other sites

Ok, but Sweden, Denmark and Finland are members of EU.

So the shipping options that might be offered are the ones for the European Union:

	define('MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_07', 'UPS Express');
define('MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_08', 'UPS Expedited');
define('MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_11', 'UPS Standard');
define('MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_54', 'UPS Worldwide Express Plus');
define('MODULE_SHIPPING_UPSXML_SERVICE_CODE_EU_ORIGIN_65', 'UPS Saver');

They don't get special shipping options.

Link to comment
Share on other sites

I am getting a mysql error on my shopping cart box and shopping_cart.php page:

 

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/jennbaca/public_html/shop/includes/functions/database.php on line 99

That is not an error with your database but with your code. Since you got it on two files it is most likely in includes/classes/shopping_cart.php. The error is that you added code but incompletely.

The correct way of doing a query is first stating the query (example):

$product_query = tep_db_query("select products_id, products_price, products_tax_class_id, products_weight from " . TABLE_PRODUCTS . " where products_id = '" . (int)$products_id . "'");

Then getting the results of the query, for example with:

$product = tep_db_fetch_array($product_query);

You have a case where only the second line is in the code or you made a typo in the second line using the variable in tep_db_fetch_array($product_query). If you use e.g. $products_query instead of $product_query you get the same error.

Link to comment
Share on other sites

Which UPS XML documentation are you actual talking about. I am trying to find it through our online account at UPS.

It is not the easiest to find but you have to find it in UPS Online Tools. There is documentation somewhere for implementing their tools (for developers). You would need to download the file dtk_RateXML.zip somewhere under Rates and Services. It's a 2 MB file.

Link to comment
Share on other sites

Hello Jan,

 

Thanks.

 

We have now downloaded that file from UPS.

 

I did find the codes for EU and it is quite similar to all the other countries so I dont really know why only

the saver are the only choice we have in your xml-documents?

Link to comment
Share on other sites

I did find the codes for EU and it is quite similar to all the other countries so I dont really know why only

the saver are the only choice we have in your xml-documents?

UPSXML only can show what UPS offers for quotes. If they only offer UPS Saver there is nothing this module can do about it. So only UPS can answer that question.

Link to comment
Share on other sites

  • 3 weeks later...

Im getting this error:

Warning: constant() [function.constant]: Couldn't find constant UPSXML_Array in /home/custom/public_html/catalog/includes/modules/shipping/upsxml.php on line 1017

 

can someone help please!!!!

 

The URL to the UPS XML Rates and Services Module (1.01):

 

http://www.oscommerce.com/community/contri...ons,1323/page,3

 

 

Torin...

Link to comment
Share on other sites

I think you're using an old version of PHP or haven't followed all the module installation instructions.

 

You can comment that function out if you're not using disallowed shipping options.

 

Im getting this error:

Warning: constant() [function.constant]: Couldn't find constant UPSXML_Array in /home/custom/public_html/catalog/includes/modules/shipping/upsxml.php on line 1017

 

can someone help please!!!!

Joseph McMurry
Web Developer
PHP/MySQL

http://www.mcmwebsite.com
 

Link to comment
Share on other sites

Im getting this error:

Warning: constant() [function.constant]: Couldn't find constant UPSXML_Array in /home/custom/public_html/catalog/includes/modules/shipping/upsxml.php on line 1017

So you skipped step 3 of the readme.txt. The error is described there too by the way.

Link to comment
Share on other sites

My company is currently using a distributor which has 3 different locations across the US. Is it possible for me to specify multiple origin zipcodes and for the module to pick the closest?

Edited by p0ng
Link to comment
Share on other sites

Anyone know what the "Ready to ship" option is for?

See the included file dimensions.txt:

As with earlier versions, you can designate a product as "Ready-to-ship". This will mean it ships in its own box of the size you specify. The algorithm will not try to put it in another box.
Link to comment
Share on other sites

My company is currently using a distributor which has 3 different locations across the US. Is it possible for me to specify multiple origin zipcodes and for the module to pick the closest?

If you can find a method/code to determine the closest zipcode relative to the zipcode of the address of the customer than I'm sure you can add that to UPSXML. However, this is not built-in in UPSXML. Haven't seen it either here but perhaps if you know how zipcodes are spread over the US you can make something that does a fair job.

Link to comment
Share on other sites

  • 4 weeks later...
So you skipped step 3 of the readme.txt. The error is described there too by the way.

 

I too am getting this error:

Warning: constant(): Couldn't find constant UPSXML_US_01 in ...

 

I did not skip Step #3 - and copied and pasted with the same result. I also, reinstalled the contribute files twice (to make sure I didn't put a file in the wrong area).

 

Can anybody shed light on something I might have overlooked?

 

Thanks!

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