diff options
| author | Savetheinternet <savetheinternet@tinyboard.org> | 2011-11-20 16:19:00 +1100 |
|---|---|---|
| committer | Savetheinternet <savetheinternet@tinyboard.org> | 2011-11-20 16:19:00 +1100 |
| commit | 3380c3008f2922b39243a2816a0cf0a9a6a029a3 (patch) | |
| tree | 6e2b525b1903cc0fb8b908499797ff45d806978a | |
| parent | 7e40483b68c5a032caf7d0b762895eb1f5a8d3f6 (diff) | |
Better SSL support.
| -rw-r--r-- | inc/functions.php | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/inc/functions.php b/inc/functions.php index 2ba4abc4..74e94ea6 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -40,8 +40,7 @@ if(!isset($config['referer_match'])) $config['referer_match'] = '/^' . (preg_match($config['url_regex'], $config['root']) ? '' : - (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] && $_SERVER['HTTPS'] != 'off' ? 'https' : 'http') . - ':\/\/'.$_SERVER['HTTP_HOST']) . + 'https?:\/\/'.$_SERVER['HTTP_HOST']) . preg_quote($config['root'], '/') . '(' . str_replace('%s', '\w+', preg_quote($config['board_path'], '/')) . |
