- Created index-simple.php (better for MAMP buffering) - Created generate-simple.php (waits for completion, no streaming) - Shows loading spinner instead of trying to stream output - Works perfectly with MAMP's output buffering - Added test pages for debugging - Use index-simple.php for MAMP, index.php for production Apache
36 lines
1.3 KiB
PHP
36 lines
1.3 KiB
PHP
<?php
|
|
echo "PHP is working!<br>";
|
|
echo "PHP Version: " . phpversion() . "<br>";
|
|
echo "Current directory: " . __DIR__ . "<br>";
|
|
|
|
// Test config loading
|
|
try {
|
|
require_once __DIR__ . '/config.php';
|
|
echo "✓ config.php loaded<br>";
|
|
echo "Python script: " . PYTHON_SCRIPT . "<br>";
|
|
echo "Python venv: " . PYTHON_VENV . "<br>";
|
|
echo "Project root: " . PROJECT_ROOT . "<br>";
|
|
echo "Reports dir: " . REPORTS_DIR . "<br>";
|
|
echo "SSO Enabled: " . (SSO_ENABLED ? 'true' : 'false') . "<br>";
|
|
} catch (Exception $e) {
|
|
echo "ERROR loading config: " . $e->getMessage() . "<br>";
|
|
}
|
|
|
|
// Test if files exist
|
|
echo "<br>File checks:<br>";
|
|
echo "Python script exists: " . (file_exists(PYTHON_SCRIPT) ? '✓ Yes' : '✗ No') . "<br>";
|
|
echo "Python venv exists: " . (file_exists(PYTHON_VENV) ? '✓ Yes' : '✗ No') . "<br>";
|
|
echo "Reports dir exists: " . (is_dir(REPORTS_DIR) ? '✓ Yes' : '✗ No') . "<br>";
|
|
|
|
// Test AuthMiddleware
|
|
echo "<br>Auth test:<br>";
|
|
try {
|
|
require_once __DIR__ . '/AuthMiddleware.php';
|
|
$auth = new AuthMiddleware();
|
|
echo "✓ AuthMiddleware loaded<br>";
|
|
echo "SSO Enabled: " . ($auth->isSSOEnabled() ? 'Yes' : 'No') . "<br>";
|
|
} catch (Exception $e) {
|
|
echo "ERROR loading AuthMiddleware: " . $e->getMessage() . "<br>";
|
|
echo "Stack trace:<br><pre>" . $e->getTraceAsString() . "</pre>";
|
|
}
|
|
?>
|