<?php
$con = mysql_connect('localhost','root','');
<?php
$con = mysql_connect('localhost','root','');
$db = mysql_select_db('myuploads',$con);$un = $_GET['usname'];
$ps = $_GET['passwd'];
$retr = mysql_query("SELECT uname,password FROM user WHERE uname = '$un' ");
while($row = mysql_fetch_assoc($retr)) {
if($row['uname'] == $un) {
if($row['uname']== $un && $row['password'] == $ps) {
echo "Welcome ".strtolower($un);
}
else
echo "Password doesnt match";
}
else
echo "User ".$un." doesnt exist";
}
?>