Extacting Form data
<?PHP
i(isset($_POST['regis']))
{
extract($_POST);
include("dbconn.pph");
mysql_query("insert into users values('','$user','$pwd')")
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>
<body>
<Fieldset style="width:500px">
<legend>
<H3> Resgistration</H3>
<FORM action="" method="post">
<table width="480" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><strong>User Name:</strong></td>
<td><input type="text" name="user" /></td>
</tr>
<tr>
<td><strong>Password:</strong></td>
<td><input type="password" name="pwd" /></td>
</tr>
<tr>
<td><input type="submit" name="regis" value="Register" /></td>
<td> </td>
</tr>
</table>
</FORM>
</legend>
</Fieldset>
</body>
</html>
/1
Comments 1