From 9ac9932487d0ee8bf045e492ec29240230ecdb87 Mon Sep 17 00:00:00 2001 From: Bas van de Wiel <bas@area536.com> Date: Tue, 15 May 2012 19:56:50 +0200 Subject: [PATCH] [FEATURE] BE preview for non standard SSL port Make sure port number gets appended when backend is locked to SSL and port number is set to something other than the standard 443. Change-Id: I5fcb04fa0e0b8cbde3f19e9c54366e11d14fdf8e Fixes: #37076 Releases: 6.0 Reviewed-on: http://review.typo3.org/11225 Reviewed-by: Philipp Gampe Reviewed-by: Wouter Wolters Reviewed-by: Christian Kuhn Tested-by: Christian Kuhn --- t3lib/class.t3lib_befunc.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/t3lib/class.t3lib_befunc.php b/t3lib/class.t3lib_befunc.php index a9164179e5a0..e328acdb6cf4 100644 --- a/t3lib/class.t3lib_befunc.php +++ b/t3lib/class.t3lib_befunc.php @@ -2718,6 +2718,12 @@ final class t3lib_BEfunc { } else { $domain = rtrim(t3lib_div::getIndpEnv('TYPO3_SITE_URL'), '/'); } + + // Append port number if lockSSLPort is not the standard port 443 + $portNumber = intval($GLOBALS['TYPO3_CONF_VARS']['BE']['lockSSLPort']); + if ($portNumber > 0 && $portNumber !== 443 && $portNumber < 65536 && $protocol === 'https') { + $domain .= ':' . strval($portNumber); + } } return $domain; -- GitLab