]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - inc/poche/Tools.class.php
Merge branch 'DmitrySandalov-master' into dev
[github/wallabag/wallabag.git] / inc / poche / Tools.class.php
index 7a872e7dff40e47951d222dd2994fa12590d3a9b..750553f1202637eeb4886a569c2586604530d547 100644 (file)
@@ -53,12 +53,12 @@ class Tools
 
         $scriptname = str_replace('/index.php', '/', $_SERVER["SCRIPT_NAME"]);
 
-        if (!isset($_SERVER["SERVER_NAME"])) {
+        if (!isset($_SERVER["HTTP_HOST"])) {
             return $scriptname;
         }
 
         return 'http' . ($https ? 's' : '') . '://'
-            . $_SERVER["SERVER_NAME"] . $serverport . $scriptname;
+            . $_SERVER["HTTP_HOST"] . $serverport . $scriptname;
     }
 
     public static function redirect($url = '')