[Solved] Very basic login form in html [closed]


Below is a basic login form code.

If this is fine mark it as answer.

if(isset($_POST['login']) && $_POST['login'] =='Login')
{
    $user = $_POST['user'];
    $pass = $_POST['pass'];

    if($user=='admin' && $pass="abcd")
    {
        // your success code
    }
    else
    {
        //your error code
    }
}
?>
<form action="" method="post" accept-charset="utf-8">
    <table>
        <caption>Login Form</caption>

            <tr>
                <td>User</td>
                <td><input type="text" name="user" value="" placeholder="User Name" /></td>
            </tr>

            <tr>
                <td>data</td>
                <td><input type="text" name="pass" value="" placeholder="User Name" /></td>
            </tr>
            <tr>
                <td colspan="2"><<input type="submit" name="login" value="Login"></td>

            </tr>

    </table>
</form>

solved Very basic login form in html [closed]