Results 1 to 7 of 7
  1. #1
    Join Date
    Jun 2006
    Posts
    6
    Plugin Contributions
    0

    attributes..second dropdown dependent on first?

    Does anyone know how I can make the second dropdown box dependent on the first?

    For example, for the option name color, i have pink and blue. for pink i have sizes small, medium, and large but for the color blue i only have size small. how do i make it so when a customer chooses blue the size dropdown only display size small rather than all three?

    also the two dropdown boxes are too far apart from each other. the color dropdown is like 1 inch above the size dropdown box, how can i make them closer together?

    i have searched the forums repeatedly but i was unable to find a thorough answer as to how to do this. any help is much appreciated. thanks.

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: attributes..second dropdown dependent on first?

    What you are seeking is product by stock and this is not a capability of Zen Cart right now.

    What version are you using and post a url for assistance on your boxes
    Zen-Venom Get Bitten

  3. #3
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    10,511
    Plugin Contributions
    126

    Default Re: attributes..second dropdown dependent on first?

    Re: Your first question

    The way I handled this is to describe availability in the product description (Note that Yellow is only available in size Small), and then to validate the attribute combination when the user presses "Add to Cart." A description of how to do this validation in Javascript is given in

    http://www.thatsoftwareguy.com/zencart.html

    Catching the dropdown box change to "Yellow" and repopulating the size box with just "Small" could certainly be done in Javascript. However, it would annoy users who selected "Large," then "Yellow" and then pressed "Add to Cart;" they would see a "Small Yellow" in their cart and wonder why. The validation route is probably the better one.

    Good luck,
    Scott
    That Software Guy. My Store: Zen Cart Support
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  4. #4
    Join Date
    Jan 2006
    Posts
    38
    Plugin Contributions
    0

    Default Re: attributes..second dropdown dependent on first?

    I'd really love something like this... perhaps a suggestion for teh DEV team...

  5. #5
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: attributes..second dropdown dependent on first?

    Improved attributes handling is a feature planned for (I believe) the next release of Zen Cart. This will be out "soon", as in "as soon as the team can get it finished".

  6. #6
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    10,511
    Plugin Contributions
    126

    Default Re: attributes..second dropdown dependent on first?

    This is really exciting news!!! Can someone from the Dev team comment further?
    That Software Guy. My Store: Zen Cart Support
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  7. #7
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: attributes..second dropdown dependent on first?

    Stock by attribute is coming in v1.4, as per the roadmap:
    http://www.zen-cart.com/forum/showthread.php?t=36912
    .

    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. v150 Second set of option values dependent/based on first option selected
    By Yellowstone in forum Setting Up Categories, Products, Attributes
    Replies: 4
    Last Post: 27 Aug 2012, 04:28 PM
  2. How to code dependent dropdown boxes?
    By HTsean in forum Setting Up Categories, Products, Attributes
    Replies: 4
    Last Post: 11 Apr 2008, 12:12 PM
  3. How do I set up dependent dropdown boxes?
    By Elk Hair Caddis in forum General Questions
    Replies: 0
    Last Post: 27 Mar 2008, 09:02 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
  •  
disjunctive-egg