]> git.wh0rd.org - tt-rss.git/blobdiff - logout.php
fix feedlist layout bug (take two) - remove unneeded CRs
[tt-rss.git] / logout.php
index 9af2bab61beb0b3a9e664191450a7040badbbf3f..b258067a6a83010122ba4d448e4382835adaec13 100644 (file)
@@ -7,7 +7,17 @@
        logout_user();
 
        if (!USE_HTTP_AUTH) {
-               header("Location: login.php");
+               $url_path = get_script_urlpath();
+
+               if (ENABLE_LOGIN_SSL) {
+                       $protocol = "https";
+               } else {
+                       $protocol = "http";
+               }               
+
+               $redirect_base = "$protocol://" . $_SERVER["SERVER_NAME"] . $url_path;
+
+               header("Location: $redirect_base/login.php");
        } else { ?>
        
        <html>