sysGeneric.php uses HTTP_HOST port instead of SERVER_PORT
This commit is contained in:
@@ -448,7 +448,11 @@ define('PATH_DYNAFORM', PATH_DATA_SITE . 'xmlForms/');
|
||||
define('PATH_IMAGES_ENVIRONMENT_FILES', PATH_DATA_SITE . 'usersFiles' . PATH_SEP);
|
||||
define('PATH_IMAGES_ENVIRONMENT_USERS', PATH_DATA_SITE . 'usersPhotographies' . PATH_SEP);
|
||||
define('SERVER_NAME', $_SERVER['SERVER_NAME']);
|
||||
define('SERVER_PORT', $_SERVER['SERVER_PORT']);
|
||||
|
||||
$hostParts = explode(':', $_SERVER['HTTP_HOST'] ?? '');
|
||||
$port = isset($hostParts[1]) && is_numeric($hostParts[1]) ? (int)$hostParts[1] : $_SERVER['SERVER_PORT'];
|
||||
|
||||
define('SERVER_PORT', $port);
|
||||
|
||||
// create memcached singleton
|
||||
$memcache = PMmemcached::getSingleton(config("system.workspace"));
|
||||
|
||||
Reference in New Issue
Block a user