mirror of
https://github.com/wallabag/wallabag.git
synced 2024-11-27 03:21:01 +00:00
Add support for custom http port
Now you can use wallabag behind reverse proxy (i.e Squid or Varnish) without problem with urls like wallabag.example.com:8080.
This commit is contained in:
parent
a15108e65b
commit
2d4cfc58ec
2 changed files with 3 additions and 0 deletions
|
@ -51,6 +51,7 @@ final class Tools
|
||||||
|
|
||||||
$serverport = (!isset($_SERVER["SERVER_PORT"])
|
$serverport = (!isset($_SERVER["SERVER_PORT"])
|
||||||
|| $_SERVER["SERVER_PORT"] == '80'
|
|| $_SERVER["SERVER_PORT"] == '80'
|
||||||
|
|| $_SERVER["SERVER_PORT"] == HTTP_PORT
|
||||||
|| ($https && $_SERVER["SERVER_PORT"] == '443')
|
|| ($https && $_SERVER["SERVER_PORT"] == '443')
|
||||||
|| ($https && $_SERVER["SERVER_PORT"]==SSL_PORT) //Custom HTTPS port detection
|
|| ($https && $_SERVER["SERVER_PORT"]==SSL_PORT) //Custom HTTPS port detection
|
||||||
? '' : ':' . $_SERVER["SERVER_PORT"]);
|
? '' : ':' . $_SERVER["SERVER_PORT"]);
|
||||||
|
|
|
@ -24,6 +24,8 @@
|
||||||
#################################################################################
|
#################################################################################
|
||||||
# Do not trespass unless you know what you are doing
|
# Do not trespass unless you know what you are doing
|
||||||
#################################################################################
|
#################################################################################
|
||||||
|
// Change this if http is running on nonstandard port - i.e is behind cache proxy
|
||||||
|
@define ('HTTP_PORT', 80);
|
||||||
|
|
||||||
// Change this if not using the standart port for SSL - i.e you server is behind sslh
|
// Change this if not using the standart port for SSL - i.e you server is behind sslh
|
||||||
@define ('SSL_PORT', 443);
|
@define ('SSL_PORT', 443);
|
||||||
|
|
Loading…
Reference in a new issue