Looking for a simple questionnaire in Javascript

Discussion in 'JavaScript' started by KenYN, Jan 30, 2008.

  1. #1
    I have found some server-based stuff to do this, but a simple JavaScript front-end might work better as I want to do this within a single blog page. Imagine I am selling socks. There would be the following branching hierarchical menu of options on the page, each next option appearing after the previous is selected:

    :Select sex
    Mens Socks
    *:Select type
    *Formal
    **:Select colour
    **White
    **Black
    **Patterned
    ***:Select pattern
    ***Fishbone
    ***Check
    *Informal
    **Cartoon character
    **Loud colours
    **Thermal
    Womens Socks
    *Short
    **Formal
    ***White
    ***Black
    **Informal
    ***Functional
    ***Playful
    *Medium
    *Knee
    *Thigh

    I hope you get the idea from my ASCII art. Once the user gets to the bottom of the tree, they get an chance to buy chosen item, or some other arbitrary HTML is presented. Can anyone save me having to reinvent the wheel?

    Thanks!
     
    KenYN, Jan 30, 2008 IP