40 lines
944 B
PHP
40 lines
944 B
PHP
<?php
|
|
declare(strict_types=1);
|
|
|
|
// Basic error reporting (keep strict in dev)
|
|
ini_set('display_errors', '1');
|
|
ini_set('display_startup_errors', '1');
|
|
error_reporting(E_ALL);
|
|
|
|
require_once __DIR__ . '/settings.php';
|
|
require_once __DIR__ . '/domaindata.php';
|
|
|
|
|
|
// Environment: staging|prod|local (example)
|
|
if (!defined('APP_ENV')) {
|
|
define('APP_ENV', 'local');
|
|
}
|
|
|
|
// Asset versioning
|
|
if (!defined('ASSET_VERSION')) {
|
|
define('ASSET_VERSION', 'dev-' . date('Ymd-His'));
|
|
}
|
|
|
|
// Primary domain + URL
|
|
if (!defined('APP_DOMAIN_PRIMARY')) {
|
|
define('APP_DOMAIN_PRIMARY', APP_DOMAIN_NAME);
|
|
}
|
|
if (!defined('APP_URL_PRIMARY')) {
|
|
define('APP_URL_PRIMARY', 'https://' . APP_DOMAIN_PRIMARY);
|
|
}
|
|
|
|
// API base (example)
|
|
if (!defined('APP_API_BASE')) {
|
|
define('APP_API_BASE', 'https://api.' . APP_DOMAIN_PRIMARY);
|
|
}
|
|
|
|
// Feature toggles
|
|
if (!defined('APP_DB_ENABLED')) {
|
|
define('APP_DB_ENABLED', false); // set true to enable DB connection
|
|
}
|