drop down boxes

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • meka07
    New Member
    • Dec 2006
    • 1

    drop down boxes

    Hey to everyone who visits this site, My name is Tomeka and Im a graduating senior at Mississippi Valley State, we are working on a project to mske an online trascript evaluation and the part I have was easy at first but now its confusion, I have two drop down menus the first is YEAR(2004,2005, 2006); the second is MAJOR(comp sci, info sci., mathe ed, mathe) we set up some pages with the major and yeat together, i need to know if I select 2004 and select comp sci how will that page pull up when i click the continue button? I really need help with this, I know you use the SELECT script in my code but I forgot how to do this..... please help
  • phxfreddieb
    New Member
    • Dec 2006
    • 1

    #2
    Originally posted by meka07
    Hey to everyone who visits this site, My name is Tomeka and Im a graduating senior at Mississippi Valley State, we are working on a project to mske an online trascript evaluation and the part I have was easy at first but now its confusion, I have two drop down menus the first is YEAR(2004,2005, 2006); the second is MAJOR(comp sci, info sci., mathe ed, mathe) we set up some pages with the major and yeat together, i need to know if I select 2004 and select comp sci how will that page pull up when i click the continue button? I really need help with this, I know you use the SELECT script in my code but I forgot how to do this..... please help
    select *
    from database_table
    where year='#form.yea r#' and major='#form.ma jor#'

    Comment

    • acoder
      Recognized Expert MVP
      • Nov 2006
      • 16032

      #3
      Originally posted by meka07
      Hey to everyone who visits this site, My name is Tomeka and Im a graduating senior at Mississippi Valley State, we are working on a project to mske an online trascript evaluation and the part I have was easy at first but now its confusion, I have two drop down menus the first is YEAR(2004,2005, 2006); the second is MAJOR(comp sci, info sci., mathe ed, mathe) we set up some pages with the major and yeat together, i need to know if I select 2004 and select comp sci how will that page pull up when i click the continue button? I really need help with this, I know you use the SELECT script in my code but I forgot how to do this..... please help
      Assuming you have major and year together like CompSci2004, CompSci2005, etc. and assuming the pages are HTML pages, you could have an onclick handler on the continue button:
      Code:
      <form ... name="transcript" ...>
      <select name="majorSel">...</select>
      <select name="yearSel">...</select>
      <input type="button" name="continue" value="Continue" onclick="location.href=document.transcript.majorSel + document.transcript.yearSel + '.html';">
      Make sure that each option within the select has no spaces, e.g.
      Code:
      <option value="CompSci">Comp Sci
      so the display shows spaces but the value that is passed has no spaces.

      Hope that helps.

      Comment

      Working...