Results 1 to 5 of 5
  1. #1
    Join Date
    Oct 2005
    Plugin Contributions

    Default Shipping Estimator - Change Default State

    How do I change the guest state to say "New York" in the guest mode while one is viewing "Shipping Estimator" , the default country is "USA" but the default state is not selected.

    However I do not want this default when one is logged in.

    Hope for some help.

  2. #2
    Join Date
    Oct 2005
    Plugin Contributions

    Default Re: Shipping Estimator - Change Default State

    any help appreciated

  3. #3
    Join Date
    Jan 2005
    Seminole, Florida, USA
    Plugin Contributions

    Default Re: Shipping Estimator - Change Default State

    I too am looking for the same feature.

    Oftentimes I get customers say "all you offer is 'Store Pick-up'".

    Not true. They just didn't fill in their zip code.

    I would like to change the default Country to USA (Which it is already doing) and change default State to Florida and default zip to 33777 so that at least some sort of shipping price shows and they realize we do ship products out.

    But like harry2cool wants, I don't want the defaults to fill in if they already have those defined in their profile.

    I looked into the code and it appears to be controlled by MySQL. I don't know how to define the "selected" option as it is coded.

  4. #4
    Join Date
    Sep 2003
    Plugin Contributions

    Default Re: Shipping Estimator - Change Default State

    Perhaps just customizing the Shipping Estimator with a little text of instruction would go a long way to helping customers use it right ...
    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!

  5. #5
    Join Date
    Jan 2004
    Blog Entries
    Plugin Contributions

    Default Re: Shipping Estimator - Change Default State

    Ajeh's point is well-raised. Giving default shipping rates to a generic destination isn't very accurate.

    nevertheless, if you must set defaults, edit /includes/modules/YOUR_TEMPLATE/shipping_estimator.php
    around line 37 you'll see:
       $zip_code = (isset($_SESSION['cart_zip_code'])) ? $_SESSION['cart_zip_code'] : '';
       $zip_code = (isset($_POST['zip_code'])) ? strip_tags(addslashes($_POST['zip_code'])) : $zip_code;
       $state_zone_id = (isset($_SESSION['cart_zone'])) ? (int)$_SESSION['cart_zone'] : '';
    Replace the ''at the end of the two lines with the appropriate values, as shown in red. Leave the middle line alone.
    The first value is a zip code.
    The second value is the NUMBER of the zone associated with the state you want selected. (from the Zones section in your Admin)

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.



Similar Threads

  1. Remove 'state/province' display in Shipping Estimator
    By Dukeofmodena in forum Customization from the Admin
    Replies: 1
    Last Post: 27 May 2011, 02:10 PM
  2. Fed Ex Module, Shipping Estimator, In State shipping
    By LuciStuff in forum General Questions
    Replies: 1
    Last Post: 31 Oct 2010, 12:37 AM
  3. [Done v1.3.7] State Selection in Shipping Estimator
    By Woodymon in forum Bug Reports
    Replies: 4
    Last Post: 30 Dec 2006, 12:12 PM
  4. State not dropdown at shipping estimator
    By renacuajo in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 29 Aug 2006, 11:35 PM


Posting Permissions

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