Jump to content

registration help


mancombe

Recommended Posts

hi guys i have made a registration page and login that works the problem is people can register the same username, here is what i have tried so far to prevent this but not having much luck.

 

if($num_rows==0)
{

  $sql="INSERT INTO $tbl_name VALUES('$id','$Username','$Password','$firstName','$lastName','$email')";

  $res=mysql_query($sql) or die("cannot execute");

  echo "<h1> You are Successfully Registered</h1>"; 
  }

else
    {
      echo " <h1>That user already Exist!</h1>" ;

     }  

?>    

 

 

any advice would be good  :D

Link to comment
https://forums.phpfreaks.com/topic/181156-registration-help/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.