or check for main fields of that post form...then i can be prevented...
for example...
$seq="select count(*) as cnt from tablename where username='".$_POST['username']."'";
sres=mysql_query($seq);
$srow=mysql_fetch_assoc($sres);
if($srow['cnt']>0) {
$errmsg="User with this Username already existed.";
} else
{
//do your insert operations..
}
and for empty fields doing client side validation is better...
Last edited by Shanti C; Oct 14th, 2008 at 1:14 am.
Reputation Points: 137
Solved Threads: 162
Posting Virtuoso
Offline 1,641 posts
since Jul 2008