]> git.wh0rd.org - tt-rss.git/commitdiff
set redirect_base to https:// prefix when ENABLE_LOGIN_SSL is enabled (closes #71)
authorAndrew Dolgov <fox@madoka.spb.ru>
Wed, 14 Jun 2006 07:24:15 +0000 (08:24 +0100)
committerAndrew Dolgov <fox@madoka.spb.ru>
Wed, 14 Jun 2006 07:24:15 +0000 (08:24 +0100)
login.php

index a7b6ca42a6960ee0c900e85225f181a481af10e8..2bd0d269208440e2dafa0b0528d6986db2c6ff05 100644 (file)
--- a/login.php
+++ b/login.php
@@ -7,7 +7,12 @@
        require_once "functions.php";
 
        $url_path = get_script_urlpath();
-       $redirect_base = "http://" . $_SERVER["SERVER_NAME"] . $url_path;
+
+       if (ENABLE_LOGIN_SSL) {         
+               $redirect_base = "https://" . $_SERVER["SERVER_NAME"] . $url_path;
+       } else {
+               $redirect_base = "http://" . $_SERVER["SERVER_NAME"] . $url_path;
+       }
 
        if (SINGLE_USER_MODE) {
                header("Location: $redirect_base/tt-rss.php");