hello everyone ,
Can anybody help, as i m a beginner in PHP, i try to just check user is valid or not ...
I hav 2 fields...Username and Password..as user enter username and password, click on submit button then in the same page the query execute and user is valid or not it give a message.
I just try this ..

<style type="text/css">
.style1 {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 18px;
    color: #996633;
    font-style: italic;
    font-weight: bold;
.style3 {font-size: 18px}
.style4 {font-size: 16px; }

$my_db= mysql_select_db("db_ash",$my_con);
$sql= "select loginName from member where loginName='$_POST[user]'";
$my_user= mysql_query($sql);
echo "Login User";
print "Username or Password is incorrect";


<div align="center">
<form id="form1" name="form1" method="post" action="default.php">
  <table width="283" border="0">
      <div align="left"><span class="style1">Login Page      </span>      </div>
      <td width="88" height="40" bgcolor="#AAB0B0"><span class="style3">Username</span></td>
      <td width="185" bgcolor="#AAB0B0">
          <div align="center">
            <input type="text" name="user" />           
      <td width="88" height="40" bgcolor="#AAB0B0"><span class="style3">Password</span></td>
      <td bgcolor="#AAB0B0">
        <div align="center">
          <input type="password" name="pass" />
      <td height="40" colspan="2" bgcolor="#AAB0B0"><p align="center"><a href="#" class="style4"> Forgot Password </a>&nbsp;&nbsp;&nbsp;
      <a href="#"> Change Password </a> </p>
        <p align="center">
          <input name="Submit1" type="submit" class="style1" value="LogIn" />

Please reply me....

Check your casing, in the form you use Submit1, in php submit1. They should match exactly.