403 - Forbidden
Direct access to content files is not allowed.
'; return true; } // Block access to sensitive files $sensitiveFiles = ['.htaccess', 'config.php']; foreach ($sensitiveFiles as $file) { if (basename($path) === $file && dirname($path) === '/') { http_response_code(403); echo 'Access to this file is not allowed.
'; return true; } } // Serve static files from engine/assets if (strpos($path, '/engine/') === 0 && file_exists(__DIR__ . $path)) { return false; // Let PHP server serve the file } // Route all other requests to index.php return false; // Let PHP server handle routing to index.php