Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Contrib] Shipping zoneworld


elari

Recommended Posts

After spending hours staring at the code, I decided to try a couple of other shipping modules. Interestingly the VAT worked fine on all others, and despite going through the code like for like, I couldn't figure it out. So I decided to try an older version of this contribution and it did actually work. If anyone figures it out, please let us know so that I can upgrade to the latest version and still have it functioning.

 

WhirlyGirl 8)

Link to comment
Share on other sites

  • Replies 56
  • Created
  • Last Reply

Top Posters In This Topic

Any idea why this is reading .....

 

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

Zone International

Shipping to GB : 3 MODULE_SHIPPING_ZONES_TEXT_UNITS

 

In the shipping choice area of the checkout?

 

Thanks,

Steve

Link to comment
Share on other sites

All problems posted last few days, use this one:

http://www.oscommerce.com/community/contributions,920

 

If the newer version don't work, this one does 100%:

25 May 2004 - Zones Intenational Default / Zonesworld Version 2 Author: Friends of Zonesworld

"If you're working on something new, then you are necessarily an amateur."

Link to comment
Share on other sites

First let me say, thanks so much for working on the shipping issue. I thought I was going to have to purchase another shopping cart to handle the type of shipping rates we want to do, but I think I'm just about there with your new code. I playing with the cart on my personal website before I take the plunge to move it to our large site (www.sharonandgayle.com).

 

I downloaded the zoneworld yesterday and uploaded to my website. I need to add some more zones to the list, so I made the change to the code to show 6 zones. But when I go into my admin panel to change the country codes for each zone and add the weight/rates, only the first 3 zones show up with box titles. There are boxes for the remaining zones, but no titles, and if I input data into them they don't save.

 

I have next to no knowledge about php, but can usually work through things if I see an example, but I can't figure out what else I need to change in the code. Here's what I'm trying to set up (these are all based on weights):

 

Zone 1 - US Media Mail Rates

Zone 2 - US Priority Mail Rates

Zone 3 - Canada/Mexico (Global Priority Mail Flat Rate of $7 for approximately 2-3 lbs)

Zone 4 - Selected countries in Europe, South America, & Pacific (GPM Flat Rate $9/2-3lbs.)

Zone 5 - ? Countries that we ship to by air parcel post (GPM service not available through USPS)

Zone (Last) - remainder of countries we don't ship to that will show as not available.

 

To get the differentiation between US Media and US Priority (I changed the ISO3 for USA to USM and country name to United States-Media), then added a new country for USP (United States-Priority). I changed the code from ISO2 to ISO3 so it reads the 3 digit country code rather than the 2. This seems to be working, if I can just get the additional zones added for the other countries.

 

Someone had mentioned they were having trouble figuring out how to set shipping to zero for downloaded items. I do this by making the first weight limit in the array 0:0.00, and setting the weight in my product listing to zero for items that are downloaded. If the customers orders an item with 0 weight no shipping is charged.

 

[email protected]

www.sweetpatoodies.com

Link to comment
Share on other sites

I downloaded the zoneworld yesterday and uploaded to my website.  I need to add some more zones to the list, so I made the change to the code to show 6 zones.  But when I go into my admin panel to change the country codes for each zone and add the weight/rates, only the first 3 zones show up with box titles.  There are boxes for the remaining zones, but no titles, and if I input data into them they don't save.

 

The method that I use to "replace" existing modules (in this case zones.php) is this:

In /admin/ click the Remove_button (de-activate the module)

In ../includes/modules/shipping/ remove the zones.php en in /languages/ do the same.

On your PC, in the new zones.php change :

 

// CUSTOMIZE THIS SETTING FOR THE NUMBER OF ZONES NEEDED

$this->num_zones = 3;

 

Set 3 to the # you need.

 

Upload both files to the server.

Activate in /admin/

 

I found that if the headers of additional zones (4, 5, 6 etc.) are not visible it is mostly due to the fact that you "overwrite" the existing module.

"If you're working on something new, then you are necessarily an amateur."

Link to comment
Share on other sites

John, Thanks much! I removed the zoneworld in the shipping module admin panel and then re installed it and it worked... all my zones show up with the code I added in the zoneworld.php file!!!

 

sharon

Link to comment
Share on other sites

John, Thanks much!  I removed the zoneworld in the shipping module admin panel and then re installed it and it worked... all my zones show up with the code I added in the zoneworld.php file!!!

 

sharon

 

And another happy customer leaves the osCommerce store :D

"If you're working on something new, then you are necessarily an amateur."

Link to comment
Share on other sites

  • 3 weeks later...
And another happy customer leaves the osCommerce store

:D

Hm John, maybe we should re-upload the working version of this contribution so it'll appear above elari's flawed one to reduce the number of problems - until he has it fixed (if that will ever happen)

Link to comment
Share on other sites

:D

Hm John, maybe we should re-upload the working version of this contribution so it'll appear above elari's flawed one to reduce the number of problems - until he has it fixed (if that will ever happen)

:D Heya Nils, you'll be back (by: Arnold S.) or still travelling?

 

Nice to read you again. :)

 

If your authorname is still the same it may probably/certainly reduce noise in the COM and DE forums.

 

With additional remark that version: zonesworld_v2.zip is re-uploaded because of frequent questions in different forums?

 

Pls. let nothing hold you back.

 

BTW do you know that the hotel (totally revamped) has now a 1:1 copy (the only one existing?) of the Nachtwacht?

"If you're working on something new, then you are necessarily an amateur."

Link to comment
Share on other sites

hello all

i have updated the zonesworld contrib for osc2.2 ms2

 

It support now some new features

 

- tax rate by shipping zone

- shipping fees by weight / price / boxes

 

last version is 2.2.2 in contrib section

http://www.oscommerce.com/community/contributions,920

please report bug.

 

if everything is ok i will try to work for ms3 version

 

elari

 

 

Found one bug related to Zonesworld.php as you have inserted in the code

MODULE_SHIPPING_ZONES_TAX_CLASS.

 

I changed this to: MODULE_SHIPPING_ZONESWORLD_TAX_CLASS, but still the tax is not added on the shipping charge.

 

Since I'm new to osCommerce and have none experience in coding; -are there someone that have found a solution to this module as I need different taxes to different zones and this module looks greate; - .if I could get the tax issue working???

 

Thanks for any help!

Link to comment
Share on other sites

  • 2 months later...

Hi,

 

I am having trouble getting international shipping zones to show up on my site. The different countries show up for the customer when they are registering, but when choosing shipping it gives an error. Can someone please point me to a very easy to install shipping module that adds international shipping destinations to oscommerce?

 

Thanks,

Stephen

Link to comment
Share on other sites

  • 4 weeks later...

I have just installed zonesworld. However when I go to change zones in My Store admin configuration, no zones show up and I cannot type a number in either. As I had only previously dealt with selling downloads I had not needed to uise the zones before

 

I have tried several removals and reinstallations to get zones to show up in the drop down box with no joy

 

Steve

Link to comment
Share on other sites

First off, merci beaucoup for the contrib! ;)

 

As usual, the better the contrib, the more you want it to do for you!

 

I was wondering whether there's any way of adding the "basecostincrementhack" function to this contrib.

 

I'm not good enough in PHP to see how to adapt this:

 

$table_cost = split(":" , MODULE_SHIPPING_TABLE_COST);
$shipping = 0;
 $baseSO = $table_cost[0];
$incrSO = $table_cost[1];
$costincSO = $table_cost[2];
$shipping = $baseSO + ($order_total * ($costincSO / $incrSO)- ($costincSO / $incrSO));

 

to the zones.php in zoneworld:

 

 $zones_table = split("[:,]" , $zones_cost);
      $size = sizeof($zones_table);
      for ($i=0; $i<$size; $i+=2) {
        if ($shipping_weight <= $zones_table[$i]) {
          $shipping = $zones_table[$i+1];
          $shipping_method = MODULE_SHIPPING_ZONES_TEXT_WAY . ' ' . $order->delivery['country']['title'] . ': ';
          if ($shipping_num_boxes > 1) {
            $shipping_method .= $shipping_num_boxes . 'x ';
          }
          $shipping_method .= $shipping_weight . ' ' . MODULE_SHIPPING_ZONES_TEXT_UNITS;
          break;
        }
      }

 

 

any ideas? This would be perfect but I don't know whether it will work because of the $shipping_method variable which adds another dimension in zoneworld's zones.php

 

Thanks for any input

Buesi

Thanx,

Buesi

Link to comment
Share on other sites

  • 2 weeks later...

This is a great contribution and works real well for me.

Just a quick question. i am in the UK and have customers based in Northen Ireland, Jersy & Isle of Man all these are land masses part of the UK but shipping is over water and hence delivery cost is more, is there a way I can add thse parts of the country to another zone?

 

How to do this? Please help!!

 

Kunal

Link to comment
Share on other sites

  • 5 months later...

Hi, I am using the version of the contribution that allows for "by price option." It is not, however, adding tax to the shipping module. I tried all classes at my disposal and no luck. The shipping c;lasses do work on the other shipping modules.

 

Any advice?

 

Thanks for the great contri!

Link to comment
Share on other sites

Hi, I am using the version of the contribution that allows for "by price option." It is not, however, adding tax to the shipping module. I tried all classes at my disposal and no luck. The shipping c;lasses do work on the other shipping modules.

 

Any advice?

 

Thanks for the great contri!

 

I too dont have Tax working. I have added included tax into the price already, only solution.

 

Kunal

Link to comment
Share on other sites

This is a great contribution and works real well for me.

Just a quick question. i am in the UK and have customers based in Northen Ireland, Jersy & Isle of Man all these are land masses part of the UK but shipping is over water and hence delivery cost is more, is there a way I can add thse parts of the country to another zone?

 

How to do this? Please help!!

 

Kunal

Any help on how to do this?

Link to comment
Share on other sites

  • 3 weeks later...

Hi all,

 

does anyone know a solution to this one:

 

I want to exlude only one country from the last shipping zone (the one for all other countries).

 

I found this in the contrib section:

 

/ Deactivate if billingadress is not the specified
if ($order->billing['country_id'] != "204") {
$this->enabled = false;
}


1. Locate next lines in any payment module for wich you 

want to add this code

============= BEGIN =================
// class methods
function update_status() {
global $order;

if ( ($this->enabled == true) && ((int)

MODULE_PAYMENT_RECHNUNG_ZONE > 0) ) {
$check_flag = false;
$check_query = tep_db_query("select zone_id from " . 

TABLE_ZONES_TO_GEO_ZONES . " where geo_zone_id = '" . 

MODULE_PAYMENT_RECHNUNG_ZONE . "' and zone_country_id = 

'" . $order->delivery['country']['id'] . "' order by 

zone_id");
while ($check = tep_db_fetch_array($check_query)) {
if ($check['zone_id'] < 1) {
$check_flag = true;
break;
} elseif ($check['zone_id'] == $order->delivery

['zone_id']) {
$check_flag = true;
break;
}
}

if ($check_flag == false) {
$this->enabled = false;
}
}

================== END ====================

Add the code above directly after "}"



With this option every country is disabled for this 

module except the definied one.

You also can change:

if ($order->billing['country_id'] != "204") {

to:

if ($order->billing['country_id'] == "204") {

Now every country except the definied is enabled for this 

module.

 

But this seems to be specified for payment modules? The code to put the lines after is also found in shipping modules like "flat" and "item" but not in zones.php.

 

Can I use these lines of code in zones.php or does anyone know any other code to implement in zones.php to reach my goal?

 

Thanks..

Link to comment
Share on other sites

  • 1 year later...

I am unable to modify default values in shipping module whether its flat rate or table rate or zone rate. Whatever changes I make, on pressing update button it goes back to default value. I also installed this zonesworld / Zones Intenational Default but the same result.

 

Is this related to mysql, I am using Mysql5, oscommerce-2.2ms2-060817 and php4

 

Please help.

 

Thanks

 

Sohail

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