diff --git a/templates/wp-config.php b/templates/wp-config.php index a8dc11f..6937544 100644 --- a/templates/wp-config.php +++ b/templates/wp-config.php @@ -215,6 +215,8 @@ if (!defined('WP_HOME')) { $home = filter_var($_SERVER['HTTPS'] ?? '', FILTER_VALIDATE_BOOLEAN) ? 'https://' : 'http://'; $home .= $_SERVER['SERVER_NAME'] ?? 'localhost'; + $port = $_SERVER['SERVER_PORT'] ?? ''; + (is_numeric($port) && (int)$port > 0) and $home .= sprintf(':%d', $port); define('WP_HOME', $home); unset($home); }