Results 1 to 5 of 5
  1. #1
    Join Date
    May 2007
    Posts
    17
    Plugin Contributions
    0

    Default Reading contents of shopping cart and changing the shipping method display accordingl

    Hi,
    I posted this last week and unfortunately I've not made much progress, nor have I received a satisfactory reply. Can anyone help? Thanks a million in advance

    ---------

    Hi. So here's my problem. I have a client that wants to change the text that freeshipper.php displays during the checkout process.

    Here's the rub: They want the text to change depending on what items or group of items is ordered. So for example, if someone orders a DVD they want it to read, "Free UPS Ground Shipping!" but if someone orders a tea set they want it to read, "Free USPS Priority Mail!", etc.

    I know where the language file is located and I know where to change the text, but to make it adaptable I have to do some database querying, which I also know how to do.

    What I don't know is how ZC stores the contents of the basket being checked out. What I figure is that I'll have to read the contents of the basket (by product ID, I'm guessing) and then have different text printed depending on what's in the cart.

    I know it's a dumb idea of theirs, but they're adamant and I'm stumped.

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

    Default Re: Reading contents of shopping cart and changing the shipping method display accord

    This would require quite a bit of customization ...

    What if the order contains a DVD and another product?
    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
    May 2007
    Posts
    17
    Plugin Contributions
    0

    Default Re: Reading contents of shopping cart and changing the shipping method display accord

    Thanks for responding.

    They have two categories:
    1) samples
    2) non-samples

    Orders with only samples are shipped USPS Priority Mail. Orders with non-samples are shipped UPS Ground. Mixed orders are shipped UPS Ground.

    Am I right in assuming that ZC doesn't check categories on checkout/shopping cart, but only product id's?

    Thanks again.

  4. #4
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,474
    Plugin Contributions
    6

    Default Re: Reading contents of shopping cart and changing the shipping method display accord

    Do the Samples all use the same master_categories_id or have some other indicator or flag that they are samples?

    By using a flag or field or something along that line you can test if the whole order is made up of "only samples" and if so, put a conditional statement on UPS not to show ... and if a mixed order, put a conditional statement on USPS to not show ...

    This is not hard to do, you just need to think through the conditions to test the cart and validate it for you shipping methods similar to how the Free Shipping test is done on the shipping modules ...
    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
    May 2007
    Posts
    17
    Plugin Contributions
    0

    Default Re: Reading contents of shopping cart and changing the shipping method display accord

    Yeah. The guy who originally set up their ZC install put everything in one category, so I had the idea that I'd check the product names (all samples have "sample" in their name, so it's kind of like what you describe). I guess my problem is that I can't tell where ZC stores or how it references the shopping cart. Database? Cookie? Global variables?

    If needed I'll reorganize their shop along the lines you suggest (they don't have that many products, so it's no biggy) but I guess my biggest challenge is figuring out HOW to check the order before it's finalized and placed in the DB.

    This is my first big ZC project, but I've done a lot with SQL and server-side scripting languages in the past.

    Thanks again for responding.

 

 

Similar Threads

  1. How not to display weight in Shopping Cart Contents ?
    By syadidister in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 9 Sep 2013, 02:21 PM
  2. shopping cart contents and new properties to the products
    By stitchnkitty in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 10 Nov 2009, 05:50 PM
  3. Replies: 5
    Last Post: 29 Sep 2009, 01:33 AM
  4. Shopping Cart Header and contents display problem
    By fastdc5 in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 17 Feb 2009, 10:20 PM
  5. Changing font size for shopping cart contents
    By oce328 in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 8 Feb 2009, 10:06 PM

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