<?php
# I would recommend using the include method. Redirects should always
be second choice, because they are just evil.
# Example code below
$password = md5('swordfish');
$user = 'Trucker Joe';
if ($_POST['user'] == $user && md5($_POST['password']) == $password) {
include_once('login_successful.php');
} else {
include_once('login_failed.php');
}
# Some may also hash the user to prevent injection
# http://us.php.net/manual/en/function.include.php
# http://en.wikipedia.org/wiki/Code_injection#PHP_Injection
?>

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to