-
Notifications
You must be signed in to change notification settings - Fork 33
Open
Description
wpstarter/templates/wp-config.php
Lines 219 to 230 in ad004f7
| if (!defined('WP_HOME')) { | |
| $port = is_numeric($_SERVER['SERVER_PORT'] ?? '') ? (int)$_SERVER['SERVER_PORT'] : 0; | |
| $scheme = isset($_SERVER['HTTPS']) | |
| ? (filter_var($_SERVER['HTTPS'], FILTER_VALIDATE_BOOLEAN) ? 'https' : 'http') | |
| : ($port === 443 ? 'https' : 'http'); | |
| $home = "{$scheme}://"; | |
| $home .= $_SERVER['SERVER_NAME'] ?? 'localhost'; | |
| $ports = ['https' => 443, 'http' => 80]; | |
| (($port > 0) && ($port !== $ports[$scheme])) and $home .= sprintf(':%d', $port); | |
| define('WP_HOME', $home); | |
| unset($port, $scheme, $home, $ports); | |
| } |
This file: https://github.com/ddev/ddev/blob/master/pkg/ddevapp/wordpress/wp-config-ddev.php
is being included in the ENV_VARIABLES section as so:
// Include for ddev-managed settings in wp-config-ddev.php.
$ddev_settings = dirname( __FILE__ ) . '/wp-config-ddev.php';
if ( is_readable( $ddev_settings ) && ! defined( 'DB_USER' ) ) {
require_once $ddev_settings;
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels