20 lines
602 B
PHP
20 lines
602 B
PHP
<?php
|
|
// Central configuration and bootstrap file.
|
|
|
|
// 1. Error Reporting (Development vs. Production)
|
|
// For development, show all errors. In a production environment, this should be logged, not displayed.
|
|
ini_set('display_errors', 1);
|
|
ini_set('display_startup_errors', 1);
|
|
error_reporting(E_ALL);
|
|
|
|
// 2. Session Management
|
|
// Ensures a session is started on all pages that include this file.
|
|
if (session_status() === PHP_SESSION_NONE) {
|
|
session_start();
|
|
}
|
|
|
|
// 3. Application Constants (optional, but good practice)
|
|
define('ROOT_PATH', __DIR__);
|
|
define('UPLOADS_PATH', ROOT_PATH . '/uploads');
|
|
|
|
?>
|