aboutsummaryrefslogtreecommitdiffhomepage
path: root/index.php
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2017-08-25 19:47:57 +0200
committerArthurHoaro <arthur@hoa.ro>2017-09-02 13:50:49 +0200
commita3130d2c2f27052710d4dbd51d0001190b19b383 (patch)
tree8a8d86ce757ac0796c6bf8b0e3546fed872d2088 /index.php
parent2a1292359b79ec77257583ea9d97891dfd2ddb1b (diff)
downloadShaarli-a3130d2c2f27052710d4dbd51d0001190b19b383.tar.gz
Shaarli-a3130d2c2f27052710d4dbd51d0001190b19b383.tar.zst
Shaarli-a3130d2c2f27052710d4dbd51d0001190b19b383.zip
Make work behind a reverse proxy
Without HTTP_X_FORWARDED_PORT check, might be set to false even though the user is using HTTPS, thus disabling Firefox Social block display
Diffstat (limited to 'index.php')
-rw-r--r--index.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/index.php b/index.php
index b4c4347a..de993f14 100644
--- a/index.php
+++ b/index.php
@@ -1063,10 +1063,10 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history)
1063 // -------- Display the Tools menu if requested (import/export/bookmarklet...) 1063 // -------- Display the Tools menu if requested (import/export/bookmarklet...)
1064 if ($targetPage == Router::$PAGE_TOOLS) 1064 if ($targetPage == Router::$PAGE_TOOLS)
1065 { 1065 {
1066 $data = array( 1066 $data = [
1067 'pageabsaddr' => index_url($_SERVER), 1067 'pageabsaddr' => index_url($_SERVER),
1068 'sslenabled' => !empty($_SERVER['HTTPS']) 1068 'sslenabled' => is_https($_SERVER),
1069 ); 1069 ];
1070 $pluginManager->executeHooks('render_tools', $data); 1070 $pluginManager->executeHooks('render_tools', $data);
1071 1071
1072 foreach ($data as $key => $value) { 1072 foreach ($data as $key => $value) {