Zencart product attributes (OSCommerce Spinoff)

Posted on 2006-03-22
Last Modified: 2012-08-14
Hi guys,

I'm running up against a mean deadline with this website:

and I'm looking for some help with using zencart's product attributes (these may be the same as OSCommerce product attributes).

This company is a manufacturing company who produces its products in a variaty of colors, sized, materials, thicknesses etc. and so getting the attributes right can be tricky.

What I can't figure out is how I would set up this product:
"Sandell®'s pre-formed corners are available in: stainless steel - 26g, 28g; copper - 10oz, 12oz, 16oz, and 20oz"

What I need is something like a dropdown saying "What material" where you can choose either Stainless Steel or Copper.
Then after you select a material, you are only able to select the options that pertain to that specific material. Ex, if you choose stainless steel, you can only choose 26g, or 28g (10oz, 12oz, 16oz, and 20oz are not selectable), if you choose copper you can only choose 10oz, 12oz, 16oz, and 20oz (26g and 28g are not selectable).

Here is the new product page:
Question by:blacksix
    LVL 19

    Expert Comment

    You haven't posted whether the select values have to be pulled from the database. Otherwise a single dropdown is adequate.

      <select name="material" id="material">
        <option value="null" selected="selected">-- What Material ? --</option>
        <option value="null">-- Stainless Steel --</option>
        <option value="ss-26">26g</option>
        <option value="ss-28">28g</option>
        <option value="null">-- Copper --</option>
        <option value="cu-10">10oz</option>
        <option value="cu-12">12oz</option>
        <option value="cu-16">16oz</option>
        <option value="cu20">20oz</option>

    Javascript or server-side validation can check for 'null' value and return a warning to the user; else a switch:case can be used to redirect to the appropriate product detail page. If the latter is true - then the selected value can be concatenated to a redirected product detail URL.
    LVL 5

    Author Comment

    Yes the values have to be pulled from a database. I could do this easily if I had the option of writing the code myself, I'm pretty good with PHP etc., but I'm using the attributes manager built into zencart. Can this be done? Just looking for someone with zencart specific experience on this one (that's why its an easy question worth 500 pts, zencart is not exactly mainstream, but close).
    LVL 5

    Author Comment

    Thank you for the response though.
    LVL 5

    Author Comment

    Seems I have found the answer:

    This has been referred to as "dependant attributes" in zencart.

    It is not possible out of the box, but can be done with some modification to zencart as described in the post above.

    Accepted Solution

    Closed, 500 points refunded.
    The Experts Exchange
    Community Support Moderator of all Ages

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    Problem to be resolved in this article Currently, development of website and web application can be done without writing thousands of lines of programming code by hand. Description This can be done through by using a open source framework such …
    Accessibility and Usability are two concepts that seem to be closely related.  But, too many people seem to have a distorted perception of them. During last five years, those two words have come to the day-to-day work of almost every web develope…
    The viewer will learn how to dynamically set the form action using jQuery.
    The viewer will get a basic understanding of what section 508 compliance can entail, learn about skip navigation links, alt text, transcripts, and font size controls.

    754 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now