mirror of
https://github.com/wallabag/wallabag.git
synced 2025-01-31 07:47:28 +01:00
Merge pull request #614 from wallabag/fix-host-getpocheurl
[fix] with some config, http host is different
This commit is contained in:
commit
a7f39918bf
@ -59,8 +59,10 @@ class Tools
|
|||||||
return $scriptname;
|
return $scriptname;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$host = (isset($_SERVER['HTTP_X_FORWARDED_HOST']) ? $_SERVER['HTTP_X_FORWARDED_HOST'] : (isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : $_SERVER['SERVER_NAME']));
|
||||||
|
|
||||||
return 'http' . ($https ? 's' : '') . '://'
|
return 'http' . ($https ? 's' : '') . '://'
|
||||||
. $_SERVER["HTTP_HOST"] . $serverport . $scriptname;
|
. $host . $serverport . $scriptname;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function redirect($url = '')
|
public static function redirect($url = '')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user