1
0
mirror of https://git.tt-rss.org/git/tt-rss.git synced 2025-12-13 20:15:55 +00:00

optional login form/http basic auth support

This commit is contained in:
Andrew Dolgov
2005-11-18 07:21:24 +01:00
parent 1c7f75ed2c
commit c8437f35c6
5 changed files with 61 additions and 18 deletions

View File

@@ -8,8 +8,14 @@
$link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME);
// $_SESSION["uid"] = PLACEHOLDER_UID; // FIXME: placeholder
// $_SESSION["name"] = PLACEHOLDER_NAME;
if (!USE_HTTP_AUTH) {
if (!$_SESSION["uid"]) {
header("Location: login.php");
exit;
}
} else {
authenticate_user($link);
}
initialize_user_prefs($link, $_SESSION["uid"]);
// FIXME this needs to be moved somewhere after user creation