Page 1 of 2 12 LastLast
Results 1 to 10 of 16
  1. #1
    Join Date
    Apr 2007
    Location
    Nijmegen, Netherlands
    Posts
    44
    Plugin Contributions
    0

    Default Cloning the Zone Based Rates Shipping Module?

    I tried to clone the Zone Based Rates Shipping Module but it does not work properly in the front-end.

    The shipping module can be installed, it shows up at the back-end, and I was able to configure it.
    But on the front-end, the Checkout Shipping does not continue to step 2 (it remains in Step 1 of 3 - Delivery Information).

    I followed the steps Ajeh described in http://www.zen-cart.com/forum/showthread.php?t=26216
    and copied the \includes\modules\shipping\zones.php to zones_es.php
    and changed
    Code:
    class zones {
    to
    Code:
    class zones_es {
    and
    Code:
    function zones() {
    $this->code = 'zones';
    to
    Code:
    function zones_es() {
    $this->code = 'zones_es';
    and I replaced all occurences of
    Code:
    MODULE_SHIPPING_ZONES_*
    to
    Code:
    MODULE_SHIPPING_ZONES_ES_*
    (e.g. MODULE_SHIPPING_ZONES_TEXT_TITLE to MODULE_SHIPPING_ZONES_ES_TEXT_TITLE).

    Furthermore I also cloned & changed the language file, and those labels are shown correctly at the front-end.

    What did I do wrong? What did I forget during the cloning?
    Kind Regards,
    Peter Martin, Joomla specialist
    www.db8.nl

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Cloning the Zone Based Rates Shipping Module?

    Try using zones is zoneses and ZONES is ZONESES the underscore is separating the word ZONE_ES and zones_es to conflict with zones and ZONES ...

    Also be aware not all ZONES get touched ... some reference the "Zone" data itself ...

    NOTE: if you are cloning for more Zones ... then stop ... read the information in the file:
    /includes/modules/shipping/zones.php

    on how to add more zones by changing a setting in the zones module itself and just REMOVE and INSTALL to build them ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Apr 2007
    Location
    Nijmegen, Netherlands
    Posts
    44
    Plugin Contributions
    0

    Default Re: Cloning the Zone Based Rates Shipping Module?

    Thanks for your fast reply!

    Quote Originally Posted by Ajeh View Post
    Try using zones is zoneses and ZONES is ZONESES the underscore is separating the word ZONE_ES and zones_es to conflict with zones and ZONES ...
    Aha, that could indeed be the problem! I will test it and post a followup with my findings...

    NOTE: if you are cloning for more Zones ... then stop ... read the information in the file:
    /includes/modules/shipping/zones.php

    on how to add more zones by changing a setting in the zones module itself and just REMOVE and INSTALL to build them ...
    I already successfully changed the zones to more zones. The reason I would like to clone the Zone Based Rates Shipping Module is that I have 2 different shipping methods / rates based on those zones.


    Thanks again!
    Kind Regards,
    Peter Martin, Joomla specialist
    www.db8.nl

  4. #4
    Join Date
    Apr 2007
    Location
    Nijmegen, Netherlands
    Posts
    44
    Plugin Contributions
    0

    Default Re: Cloning the Zone Based Rates Shipping Module?

    The problem was indeed caused by the underscore.

    Changing all labels from *_ZONES_ES_* to *_ZONESES_* and the class & function name + "$this->code" contents from zones_es to zoneses solved the problem.

    Thanks again for your help!
    Kind Regards,
    Peter Martin, Joomla specialist
    www.db8.nl

  5. #5
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Cloning the Zone Based Rates Shipping Module?

    Thanks for posting back that this was, in fact, the problem with your cloning of the Zone Rate zones Shipping Module ... always a great help to others ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  6. #6
    Join Date
    Apr 2007
    Posts
    6
    Plugin Contributions
    0

    Default Re: Cloning the Zone Based Rates Shipping Module?

    Wow great post.

    It works for me. http://hosting.cityemails.com
    http://www.bharatanatyamworld.com/ecart/

    Also by using this system you can even create new methods for
    diffirent online & offline business.

    I would like to say all.

    Thank You.
    Last edited by rohan; 23 Feb 2008 at 05:06 PM.

  7. #7
    Join Date
    Jul 2006
    Posts
    5
    Plugin Contributions
    0

    red flag Re: Cloning the Zone Based Rates Shipping Module?

    Please can someone help me.

    I tried to do the above suggestions, but there are so many
    MODULE_SHIPPING_ZONES_* to change, that I changed them all, and then realise that some need to be changed and others don't.

    I can't get it to work.
    When I looked at the shipping modules for download, there is no option (the one is a RAR file that I can't open, and the other does not contact countries, so it not a true zone based clone).
    Is there nowhere else to download this module.

    If not could anyone please advise which MODULE_SHIPPING_ZONES_* I need to change and which ones I don't.

    I'm desperate to do this as I have two courier options at two different transit times and rates.
    Thanks so much in advance if anyone can help.
    Dean

  8. #8
    Join Date
    Nov 2006
    Posts
    14
    Plugin Contributions
    0

    Default Re: Cloning the Zone Based Rates Shipping Module?

    Quote Originally Posted by Deansta View Post
    Please can someone help me.

    I tried to do the above suggestions, but there are so many
    MODULE_SHIPPING_ZONES_* to change, that I changed them all, and then realise that some need to be changed and others don't.

    I can't get it to work.
    When I looked at the shipping modules for download, there is no option (the one is a RAR file that I can't open, and the other does not contact countries, so it not a true zone based clone).
    Is there nowhere else to download this module.

    If not could anyone please advise which MODULE_SHIPPING_ZONES_* I need to change and which ones I don't.

    I'm desperate to do this as I have two courier options at two different transit times and rates.
    Thanks so much in advance if anyone can help.
    Dean
    Any update? I am looking for a way to duplicate the zone rate shipping module too.

  9. #9
    Join Date
    Feb 2007
    Posts
    513
    Plugin Contributions
    2

    Default Re: Cloning the Zone Based Rates Shipping Module?

    [FONT=Verdana]Can anyone send me the 2 files they edited successfully and I will add it to the contributions[/FONT]

  10. #10
    Join Date
    Feb 2007
    Posts
    513
    Plugin Contributions
    2

    Default Re: Cloning the Zone Based Rates Shipping Module?

    Am I suppose to change

    PHP Code:
     
    // class constructor
        
    function zones() {
          
    $this->code 'zones'
    to

    PHP Code:
    // class constructor
        
    function zones2() {
          
    $this->code 'zones2'
    along with the rest of the other definitions; I dont think so.. any way I will keep on trying

    For all the people that have got it to work it (many posts on this subject) would have been nice to see some one post the file in their replyy or add it to the contributions

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Zone Rates Cloning?
    By gabstero in forum Addon Shipping Modules
    Replies: 3
    Last Post: 4 Mar 2014, 07:11 PM
  2. Different shipping rates based on zone?
    By Dunk in forum Built-in Shipping and Payment Modules
    Replies: 26
    Last Post: 15 Oct 2010, 05:02 PM
  3. zone shipping rates module
    By abhishek77 in forum General Questions
    Replies: 0
    Last Post: 28 Apr 2008, 01:34 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR