thezeppzone
03-05-2005, 11:52 PM
how do i do like an if structure for a php poll with radio answers? like, my inputs are radios, and theres 5 of them, i guess the big question is, how do i determine if a user selected that box? i tried using what a tutorial i found online said but it didnt work....
thanks, zepp
bejayel
03-06-2005, 11:20 PM
depends on which posting method you use. i usually use get
<form method="get" action="poll.php">
<radio name="blah" value="hehe">
</form>
<?
$variable = $_GET['blah'];
?>
or
<form method="post" action="poll.php">
<radio name="blah" value="hehe">
</form>
<?
$variable = $_POST['blah'];
?>
I think that should do it. Try it out.