View Full Version : quiz issue


thezeppzone
12-01-2004, 03:41 AM
Well, i couldnt seem to find a problem in my coding, so i dont know whats up. this used to work, but i tried it just now while redoing my site and it didnt. i formatted this quiz different than my others, but not very much different, when u click submit nothing happens. i have all my html files, my error file, everything,

linkie here (http://www.whalersfan.com/thezeppzone/quizzes/me/index.html)

html here(now that u can all see my answers lololol)
<html>
<head>

<meta http-equiv="imagetoolbar" content="no">

<title>[diminished quiz]</title>

<link href="http://www.whalersfan.com/thezeppzone/maincss.css" rel="stylesheet" type="text/css">

<SCRIPT LANGUAGE="JavaScript">
<!--
function process()
{
var great = 0;
var horrible = 0;
var f = document.f;
var i = 0;

for (i = 0; i < f.one.length; i++) if (f.one[i].checked) value = f.one[i].value;
if (value == "3") { great++; }

for (i = 0; i < f.two.length; i++) if (f.two[i].checked) value = f.two[i].value;
if (value == "2") { great++; }

for (i = 0; i < f.three.length; i++) if (f.three[i].checked) value = f.three[i].value;
if (value == "4") { great++; }

for (i = 0; i < f.four.length; i++) if (f.four[i].checked) value = f.four[i].value;
if (value == "5") { great++; }

for (i = 0; i < f.five.length; i++) if (f.five[i].checked) value = f.five[i].value;
if (value == "1") { great++; }

if (great == 5) { out = "great" }
if (great == 4) { out = "good" }
if (great == 3) { out = "ok" }
if (great == 2) { out = "bad" }
if (great == 1) { out = "horrible" }


location.href = out + ".html";
}
function err(msg, url, line)
{
location.href = "error.html";
}
//window.onerror = err;
// -->
</SCRIPT>

</head>


<body>
<font color="#996666" size="1" face="tahoma">
<p align="left">

<b>how well do you know me</b><br><br><br>
<form name="f">
[<font color="#669966">what is my favorite sport</font>]<br>
<input type="radio" name="one" value="1">&nbspsoccer<br>
<input type="radio" name="one" value="1">&nbspbaseball<br>
<input type="radio" name="one" value="3">&nbsphockey<br>
<input type="radio" name="one" value="4">&nbspfootball<br>
<input type="radio" name="one" value="5">&nbspbasketball<br><br><br>

[<font color="#669966">what is my middle name</font>]<br>
<input type="radio" name="two" value="1">&nbspjames<br>
<input type="radio" name="two" value="2">&nbspmichael<br>
<input type="radio" name="two" value="3">&nbspjoseph<br>
<input type="radio" name="two" value="4">&nbspthomas<br>
<input type="radio" name="two" value="5">&nbspcarl<br><br><br>

[<font color="#669966">how many people are in my family</font>]<br>
<input type="radio" name="three" value="1">&nbsp2<br>
<input type="radio" name="three" value="2">&nbsp3<br>
<input type="radio" name="three" value="3">&nbsp4<br>
<input type="radio" name="three" value="4">&nbsp5<br>
<input type="radio" name="three" value="5">&nbsp6<br><br><br>

[<font color="#669966">what instrument do i play</font>]<br>
<input type="radio" name="four" value="1">&nbspflute<br>
<input type="radio" name="four" value="2">&nbsptrumpet<br>
<input type="radio" name="four" value="3">&nbspclarinet<br>
<input type="radio" name="four" value="4">&nbsptrombone<br>
<input type="radio" name="four" value="5">&nbspsaxophone<br><br><br>

[<font color="#669966">what kind of car do i want</font>]<br>
<input type="radio" name="five" value="1">&nbspcts<br>
<input type="radio" name="five" value="2">&nbspcorvette<br>
<input type="radio" name="five" value="3">&nbspjetta<br>
<input type="radio" name="five" value="4">&nbspmustang<br>
<input type="radio" name="five" value="5">&nbsphummer<br><br><br>

<input type="button" value="click me" onclick="process();">

<br><br><br><br><br><br><br><br>[<a href="javascript:history.go(-1)"
onMouseOver="self.status=document.referrer;return true">back</a>]

</p>
</font>
</body>
</html>


thanks


zeppy