login: redirect to main page if user is already logged in

This commit is contained in:
Andrew Dolgov 2006-03-17 03:55:38 +01:00
parent 9eda83417b
commit a5ebd1f974
1 changed files with 8 additions and 0 deletions

View File

@ -19,6 +19,14 @@
$login = $_POST["login"];
$password = $_POST["password"];
if ($_COOKIE["ttrss_sid"]) {
require_once "sessions.php";
if ($_SESSION["uid"]) {
initialize_user_prefs($link, $_SESSION["uid"]);
header("Location: $redirect_base/tt-rss.php");
}
}
if ($login && $password) {
if ($_POST["remember_me"]) {