0

can any one please help me,by telling how to create a check box.

<form name="frm" action="action.php">

<tr><td><input type="check box" name="box[]"
 value="--" </td></tr>
</form>

can any one tell me what should be passed as the value and what should the action .php contain...

please help ..

2
Contributors
4
Replies
5
Views
7 Years
Discussion Span
Last Post by muralikalpana
0
<form name="frm" action="action.php">

<tr><td><input type="check box" name="box"
 value="1" ></td></tr>
<tr><td><input type="submit" name="submit" value="submit"></td></tr>
</form>

in action.php

<?
echo $_REQUEST[box];
?>

Edited by muralikalpana: n/a

0
<form name="frm" action="action.php">

<tr><td><input type="check box" name="box"
 value="1" ></td></tr>
<tr><td><input type="submit" name="submit" value="submit"></td></tr>
</form>

in action.php

<?
echo $_REQUEST[box];
?>
if it is  a registration page and am subbmitting values to a db,through a form, what should be the action page?
0
if it is  a registration page and am subbmitting values to a db,through a form, what should be the action page?

you can write php code witn in the page also. just execute this code.

<?
ob_start();
extract($_POST);
echo $box;
if($_POST)
{
//write insert query here
}
?>
      <form name="frm" action=" " method="post">
<table>
    <tr><td><input type="check box" name="box" value="1"></td></tr>
   <tr><td><input type="submit" name="submit" value="submit"></td></tr>
</table>
      </form>

Edited by muralikalpana: n/a

0
<?
$con = mysql_connect("localhost","username","password");
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }
$db=mysql_select_db('dbname',$con);
?>

write this in php code.

Edited by muralikalpana: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.