plz tell me whats wrong with this.....plz reply soon
PHP Code:
<?php
$a = $_POST['T1'];
$b = $_POST['T2'];
$c = $_POST['T3'];
$d = $_POST['T4'];
$e = $_POST['T5'];
$f = $_POST['T6'];
$con = mysql_connect("localhost", "root", "");
if(!$con)
{
echo "error in connection".mysql_error();
}
mysql_select_db("uc", $con);
$q = mysql_query("insert into members values('$a',$b','$c','$d','$e','$f'",$con);
if(!$q)
{
echo "error in query".mysql_error();
}
if($r = mysql_fetch_array($q))
{
session_start();
$_SESSION['sname'] = $a;
header("location:confrmreg.php");
}
else
{
echo "invalid id or password try again";
}
?>
Comment