Jump to content

Form w/ 2 drop-down boxes, submit button, links PLS HLP:)


chin88

Recommended Posts

Hi All,

 

This is my first post! I think this site is amazing. I love the little try it yourself windows. SO cool.

 

 

So my question is this: how can I make a form that has two drop down menus (the first with 2 options and the second with 3) and a submit button which upon clicking will take the user to one of 6 html pages on my website.

 

Drop down 1: -Fairy Goddess

-Inner Warrior

 

Drop down 2: -Young Adult

-20 Something

-30 and up

 

 

Possible outcomes: 1. Fairy Goddess - Young Adult

2. Fairy Goddess - 20 Something

3. Fairy Goddess - 30 and up

4. Inner Warrior - Young Adult

5. Inner Warrior - 20 Something

6. Inner Warrior - 30 and up

 

I've tried to get a start by modifying this check-box & submit disclaimer code that I successfully implemented on one page. I haven't an idea how to modify the JS to match what I want to do with the HTML. Please correct and direct me to solve this! :)

 

The code I have now:

       <SCRIPT language=JavaScript><!--//Accept terms & conditions script (by InsightEye www.insighteye.com)//Visit JavaScript Kit (http://javascriptkit.com) for this script & more.function checkCheckBox(f){if (f.agree.checked == false ){alert('Please agree to the terms by checking the box to continue.');return false;}else{return true;}}//-->  </SCRIPT>

followed by:

<!-- Consultation form code -->                         <form action="fairy-goddess.html" autocomplete="on">  Choose your Guide               <input list="guides" name="guide">                <datalist id="guides">                  <option value="Fairy Goddess">                  <option value="Inner Warrior">                 </datalist><br>                 Choose your age group               <input list="age-groups" name="age-group">                <datalist id="age-groups">                  <option value="Young Adult">                  <option value="20 Something">                  <option value="30 & up">                 </datalist><br>  <input type="button" class="btn btn-default" value="Submit" onclick="document.location.href='../disclaimer.html';"></form><!-- Consultation form code --> 

THANKS!!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...