Jump to content

Script Wont Work


Recommended Posts

I am trying to make a multiple choice quiz,but for some reson it wont work.

<div align="center">
<p>
General Hood fought for which side in the Civil War?
<form method="post" action="qtwo.php">
<p>
<input type="radio" name="qone" value="1">Union<br>
<input type="radio" name="qone" value="2">Rebel<br>
<input type="radio" name="qone" value="3">Patriot<br>
<br>
<button type="submit"><img src="submit.png"></button>
</form>
</p>
</div>

 

and

 

$_POST['qone'] = $qone;
include ('head.php');
if ($qone == 2)
{echo "<p>
Your answer was correct!</p>";}
else
{echo "<p>
Sorry, General Hood fought for the rebels or Confederates.</p>";}

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...