The username of my website has been saved like robert and the interesting thing is that someone Name Robert (Capital R) How do I stop them from repetitive usernames in any way? My project is in MySQL / php Also registered with this code Robert In both cases, convert them both and then compare them as: / P>
if (mysql_num_rows (Mysql_query ("user_table WHERE user name =" $ user name "select username)) & gt; 0) {Die ("Duplicate user names can not be saved, this username is present.");}
Table WHERE LOWER (username) = Select user name from LOWER ('$ username')
Comments
Post a Comment