Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

online quiz thing...

Status
Not open for further replies.

mattbold

Programmer
Oct 5, 2001
45
GB
hi,
thanks everyone for all your help on here so far,
and now i have another query!

basically, one of my friends has asked me to get this sorted or he'll hurt me, so any help would be much appreciated!!

yeah what we're doing is making one of those online quiz things where you get a question and you can choose an answer from a selection of answers by clicking on the corresponding radio button. different answers would have different "weights", there would be maybe 5 questions on a page, then u could click on a button that takes you to the next page.
at the end the weighting from the answers would be added up and depending on what the total is you are placed in a category...

i am thinking this could be done in vbscript, but ive never used radio buttons in web pages before so im really not sure how to sort out the weighting for each answer...

cheers,
matt
 
1. This is Question 1?<br>
<p><input type=&quot;radio&quot; name=&quot;question1&quot; value=&quot;1&quot;>This is the first answer to question 1.<br>
<input type=&quot;radio&quot; name=&quot;question1&quot; value=&quot;2&quot;>This is the second answer to question 1.<br>
<input type=&quot;radio&quot; name=&quot;question1&quot; value=&quot;3&quot;>This is the third answer to question 1.<br>
<input type=&quot;radio&quot; name=&quot;question1&quot; value=&quot;4&quot;>This is the fourth answer to question 1.<br>
<input type=&quot;radio&quot; name=&quot;question1&quot; value=&quot;5&quot;>This is the fifth answer to question 1.</p>

Make the value to each answer it's weight. And the name to each answer for the same question the same, so only one can be selected. Then at the end, you total the values of all the answer and divide by number of questions, or just average them, however you do the math. Gives you the average weight of their answers.

Does that help?


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top