|
<?php |
|
|
|
// Check if a enviroment file is defined and include it. |
|
if ( is_file( dirname( __DIR__ ) . '/env-config.php' ) ) include( dirname( __DIR__ ) . '/env-config.php' ); |
|
if ( is_file( dirname( __FILE__ ) . '/env-config.php' ) ) include( dirname( __FILE__ ) . '/env-config.php' ); |
|
|
|
//==================================================================== |
|
// Below should only contain the defaults for local development |
|
//==================================================================== |
|
|
|
// Database |
|
defined( 'DB_NAME' ) or define( 'DB_NAME', 'wp' ); |
|
defined( 'DB_USER' ) or define( 'DB_USER', 'wp' ); |
|
defined( 'DB_PASSWORD' ) or define( 'DB_PASSWORD', 'wp' ); |
|
defined( 'DB_HOST' ) or define( 'DB_HOST', 'localhost' ); |
|
// Url |
|
// Url |
|
$http_s = ( isset($_SERVER['HTTPS']) && !empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] != 'off') ? 'https' : 'http'; |
|
defined( 'WP_HOME' ) or define( 'WP_HOME', $http_s . '://example.test' ); // no trailing slash |
|
|
|
|
|
//==================================================================== |
|
// Below should be the same for every enviroment |
|
//==================================================================== |
|
|
|
$table_prefix = 'rndm_'; // please change with 2-5 random letters/digits |
|
|
|
// https://api.wordpress.org/secret-key/1.1/salt |
|
define( 'AUTH_KEY', '************************************************'); |
|
define( 'SECURE_AUTH_KEY', '************************************************'); |
|
define( 'LOGGED_IN_KEY', '************************************************'); |
|
define( 'NONCE_KEY', '************************************************'); |
|
define( 'AUTH_SALT', '************************************************'); |
|
define( 'SECURE_AUTH_SALT', '************************************************'); |
|
define( 'LOGGED_IN_SALT', '************************************************'); |
|
define( 'NONCE_SALT', '************************************************'); |
|
|
|
// Multisite |
|
defined( 'WP_ALLOW_MULTISITE' ) or define( 'WP_ALLOW_MULTISITE', false ); |
|
/* // Unquote for multisites |
|
defined( 'MULTISITE' ) or define( 'MULTISITE', true ); |
|
defined( 'SUBDOMAIN_INSTALL' ) or define( 'SUBDOMAIN_INSTALL', false ); |
|
defined( 'DOMAIN_CURRENT_SITE' ) or define( 'DOMAIN_CURRENT_SITE', 'example.com' ); // no `http://` see env-config.php |
|
defined( 'PATH_CURRENT_SITE' ) or define( 'PATH_CURRENT_SITE', '/' ); |
|
defined( 'SITE_ID_CURRENT_SITE' ) or define( 'SITE_ID_CURRENT_SITE', 1 ); |
|
defined( 'BLOG_ID_CURRENT_SITE' ) or define( 'BLOG_ID_CURRENT_SITE', 1 ); |
|
/**/ |
|
|
|
//==================================================================== |
|
// That's all, stop editing! Happy blogging. |
|
//==================================================================== |
|
|
|
// URL and paths |
|
defined( 'WP_SITEURL' ) or define( 'WP_SITEURL', WP_HOME ); |
|
defined( 'WP_CONTENT_DIR' ) or define( 'WP_CONTENT_DIR', dirname( __FILE__ ) . '/wp-content' ); |
|
defined( 'WP_CONTENT_URL' ) or define( 'WP_CONTENT_URL', WP_HOME . '/wp-content' ); |
|
defined( 'PLUGINDIR' ) or define( 'PLUGINDIR', 'wp-content/plugins' ); // Relative to ABSPATH. For back compat. |
|
defined( 'MUPLUGINDIR' ) or define( 'MUPLUGINDIR', 'wp-content/mu-plugins' ); // Relative to ABSPATH. For back compat. |
|
// DB |
|
defined( 'DB_CHARSET' ) or define( 'DB_CHARSET', 'utf8mb4' ); |
|
defined( 'DB_COLLATE' ) or define( 'DB_COLLATE', '' ); |
|
|
|
// Minor tweaks |
|
defined( 'AUTOSAVE_INTERVAL' ) or define( 'AUTOSAVE_INTERVAL', 300 ); // autosave every 300 seconds |
|
defined( 'WP_POST_REVISIONS' ) or define( 'WP_POST_REVISIONS', 10 ); // 10 post revisions |
|
defined( 'DISALLOW_FILE_EDIT' ) or define( 'DISALLOW_FILE_EDIT', true ); // don't allow to edit files in the wp-admin. |
|
defined( 'DISALLOW_FILE_MODS' ) or define( 'DISALLOW_FILE_MODS', false ); // don't alllow installing/updating of plugins. |
|
defined( 'EMPTY_TRASH_DAYS' ) or define( 'EMPTY_TRASH_DAYS', 30 ); |
|
defined( 'DISABLE_WP_CRON' ) or define( 'DISABLE_WP_CRON', true ); // disable the cron executed by visiting webpages |
|
defined( 'CORE_UPGRADE_SKIP_NEW_BUNDLED' ) or define( 'CORE_UPGRADE_SKIP_NEW_BUNDLED', true); // don't install default themes/plugins on update |
|
defined( 'WP_DEFAULT_THEME' ) or define( 'WP_DEFAULT_THEME', 'genesis'); // Set Genesis as default theme |
|
|
|
// Debug defaults |
|
if ( ( defined( 'WP_ENVIRONMENT_TYPE' ) && WP_ENVIRONMENT_TYPE === 'development' ) ) { |
|
defined( 'WP_DEBUG_DISPLAY' ) or define( 'WP_DEBUG_DISPLAY', true ); |
|
defined( 'WP_DEBUG' ) or define( 'WP_DEBUG', true ); |
|
} else { |
|
// log errors when it's not a development server |
|
defined( 'WP_DEBUG_LOG' ) or define( 'WP_DEBUG_LOG', WP_CONTENT_DIR . '/debug.log' ); |
|
defined( 'WP_DEBUG_DISPLAY' ) or define( 'WP_DEBUG_DISPLAY', false ); |
|
defined( 'WP_DEBUG' ) or define( 'WP_DEBUG', true ); // so it's logging errors. |
|
} |
|
|
|
/** Absolute path to the WordPress directory. */ |
|
if ( ! defined( 'ABSPATH' ) ) { |
|
defined( 'ABSPATH' ) or define( 'ABSPATH', dirname( __FILE__ ) . '/' ); |
|
} |
|
|
|
/** Sets up WordPress vars and included files. */ |
|
require_once( ABSPATH . 'wp-settings.php' ); |