473,800 Members | 2,499 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

validate a set of radio buttons in a quiz

29 New Member
Expand|Select|Wrap|Line Numbers
  1. <table class="special3" align="left" width="75%" height="65%" >
  2. <form>
  3. <table width="50%" align="center">
  4.  
  5. <tr align="right">
  6.  
  7. <td></td>
  8. <td><a href="http://geocities.com/blhc_69/testingignore.html">Logout</a></td>
  9. </tr>
  10.  
  11. <tr align="left"><td>
  12. <table border value="1">
  13. <td><a href="http://geocities.com/blhc_69/second2.html">Home</a></td>
  14. </table></td>
  15. </tr>
  16.  
  17. <tr>
  18. <th class="row"><font size="+4">SCIENCE QUIZ</font></th><th></th>
  19. </tr>
  20.  
  21. <tr><td>1.A person who studies the substances in living things might best be called:</td></tr>
  22. <tr><td><input type="radio" name="group1" checked value="a">biochemist</td></tr>
  23. <tr><td><input type="radio" name="group1" value="b">homeopath</td></tr>
  24. <tr><td><input type="radio" name="group1" value="c">naturopath</td></tr>
  25. <tr><td><input type="radio" name="group1" value="d">pharmacist</td></tr>
  26. <tr><td><br/></td></tr>
  27.  
  28. <tr><td>2.The study of animal or human movement is called:</td></tr>
  29. <tr><td><input type="radio" name="group2" checked value="a">physiotherapy</td></tr>
  30. <tr><td><input type="radio" name="group2" value="b">chiropractory</td></tr>
  31. <tr><td><input type="radio" name="group2" value="c">physical education</td></tr>
  32. <tr><td><input type="radio" name="group2" value="d">biomechanics</td></tr>
  33. <tr><td><br/></td></tr>
  34.  
  35. <tr><td>3.A scientist who studies how electrical signals affect the human body might be a:</td></tr>
  36. <tr><td><input type="radio" name="group3" checked value="a">electrician</td></tr>
  37. <tr><td><input type="radio" name="group3" value="b">radiologist</td></tr>
  38. <tr><td><input type="radio" name="group3" value="c">physiotherapist</td></tr>
  39. <tr><td><input type="radio" name="group3" value="d">biophysicist</td></tr>
  40. <tr><td><br/></td></tr>
  41.  
  42. <tr><td>4.The study of substance properties and how they react is called:</td></tr>
  43. <tr><td><input type="radio" name="group4" checked value="a">chemistry</td></tr>
  44. <tr><td><input type="radio" name="group4" value="b">pharmacy</td></tr>
  45. <tr><td><input type="radio" name="group4" value="c">physics</td></tr>
  46. <tr><td><input type="radio" name="group4" value="d">biology</td></tr>
  47. <tr><td><br/></td></tr>
  48.  
  49. <tr><td>5.The study of stars, planets and other heavenly bodies is called:</td></tr>
  50. <tr><td><input type="radio" name="group5" checked value="a">astrology</td></tr>
  51. <tr><td><input type="radio" name="group5" value="b">physics</td></tr>
  52. <tr><td><input type="radio" name="group5" value="c">astronomy</td></tr>
  53. <tr><td><input type="radio" name="group5" value="d">telescopy</td></tr>    
  54. <tr><td><br/></td></tr>
  55.  
  56. <tr><td><input type="submit" value="submit my quiz!" onclick="checkscore(group1)"><input type="reset" 
  57.  
  58. value="Clear my quiz!"></td>
  59. </table>
  60. </form>
  61. </table>
how do i validate all these buttons?? i want to check the answers then dsplay the outcome of this quiz
Apr 10 '09 #1
3 1761
hsriat
1,654 Recognized Expert Top Contributor
Dear 1051109210,

What do you mean by validate here?
Apr 10 '09 #2
1051109210
29 New Member
@hsriat
nvm its alright figured out . thanks
(i meant that i want it to check the score of the quiz)
Apr 11 '09 #3
acoder
16,027 Recognized Expert Moderator MVP
You do realise that anyone can view the source to see the answers?
Apr 13 '09 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

1
3424
by: Dave | last post by:
Hi, there used to be a simple javascript quiz builder in builder.com, with which I made the page whose code is given below. I would like to tweak this so that there are only three (not 4) answer options, and that they are presented alongside radio buttons (not in a selectable list). I would be grateful if someone knows how to do this for me. It would be nice if the student doing the quiz selects the right answer with the radio button,...
2
2693
by: Dave | last post by:
I have a page which uses JavaScript to create form elements using document.createElement('input'), etc.. Both Firefox and IE have no problem accomplishing this and when the form is submitted all the information is passed correctly. I am now trying to validate the form using JavaScript when the page is submitted. Firefox has no problems with this but IE returns 'document.form1.*THE FORM FIELD*.value is null or not an object' for the...
2
3495
by: NishSF | last post by:
Would anyone have any suggestions/javascript code so that if one clicks the Radio Button "Yes" below he has the option of selecting any of the six CheckBox below. If the user clicks on Radio Button "No", he should not have the option of clicking on any of the six checkboxes. See Code attached. Thank you so much in advance for your help as I can't get to make this combo work. <p>Did you have any problems finding any of the information...
1
8860
by: Jerry | last post by:
We have a 10-question quiz for kids, each question being a yes or no answer using radio selections. I'd like to keep a current total of yes's and no's at the bottom of the quiz (if the user selects yes to question 1, the total of yes's increases by 1). I've been searching for a while but I'm not sure I'm searching with the right keywords. Can anyone direct me to a source I can review to learn how to do this? Thanks! --
11
8198
by: TokyoJ | last post by:
I run a small camp in Alaska for kids and my director is asking for a web form. Could someone please have a look and offer some advice on where I'm making mistake(s)? I'm using the RegExp function to validate 3 types of fields: text, radio button, dropdown menu. but the code doesn't validate. After 2 days, it's time I asked for guidence. Criteria: Text: only alphabet, no numerals, allowed Radio: one must be selected, Dropdown: an option...
9
3853
sanjay123456
by: sanjay123456 | last post by:
Dear Friends , i have i problem that let say suppose i am working in index.php and <form name="myform" method="POST" action="<?php echo $_SERVER; ?> ">
2
5897
by: dpazza | last post by:
Hi, I'm creating a quiz on using a form in VB 2005 express. I have four sets of questions and answers (labels and radio buttons) and I change between which set of questions is currently shown on the form by changing the visible state of the radio buttons and labels utilising back and next buttons. E.g. Next button makes current radio buttons and labels invisible and
1
1332
by: anuva | last post by:
Hi, I am new to asp and developing a quiz portal. I need a help for this. I am using MS Access database which is having a table called 'Quiz_Master' having fields such as 'Quiz_id', 'Quiz_Name', 'Quiz_Date','IsCurrent','Deleted'. Here is my requirement: 1. I want a page where there will be radio buttons whose value will come from the above table showing all the list of 'Quiz_Name'.
3
4009
by: sethupnr | last post by:
hi. I need to create a Quiz program in flash. The question's answers are given as radio button for selection. There is also 2 button "next" and " previous". How can i do this. By "previous" button i have to go back to previous qn and change the answer. How to display the previously selected answer(in radio buttons).Plz help...
0
10274
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10251
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10033
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9085
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6811
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5469
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5606
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3764
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2945
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.