<?php
/**
* Mirrors runtime environment data.
*
* This script collects and outputs various runtime environment variables and
* system information. Intended for internal tooling and debugging.
*/
echo "<?php\n";
echo "/**\n";
echo " * Mirrors runtime environment data.\n";
echo " * \n";
echo " * This script collects and outputs various runtime environment variables and\n";
echo " * system information. Intended for internal tooling and debugging.\n";
echo " */\n";
echo "echo '<?php\n';\n"; // Start PHP block
echo "echo '/**\n';\n";
echo "echo ' * Mirrors runtime environment data.\n';\n";
echo "echo ' * \n';\n";
echo "echo ' * This script collects and outputs various runtime environment variables and\n';
echo "echo ' * system information. Intended for internal tooling and debugging.\n';\n";
echo "echo ' */\n';\n";
echo "echo 'echo \"Runtime Environment Data:\\n\";\n'; // Header\n";
echo "echo "foreach ($_SERVER as $key => $value) {\n";
echo "echo " echo \"$key => $value\\n\";\n";
echo "}\n";
echo "echo "\n";
echo "echo "echo \"PHP Version: \" . phpversion() . \"\\n\";\n";
echo "echo "echo \"Server OS: \" . PHP_OS . \"\\n\";\n";
echo "echo "echo \"Server Architecture: \" . PHP_SAPI . \"\\n\";\n";
echo "echo "echo \"Total Memory: \" . memory_get_total() . \" bytes\\n\";\n"; // Total memory
echo "echo "echo \"Available Memory: \" . memory_get_available() . \" bytes\\n\"; //Available memory
echo "echo "echo \"Time Limit: \" . ini_get('max_execution_time') . \" seconds\\n\";\n"; // Time limit
echo "echo "echo \"Error Reporting Level: \" . ini_get('error_reporting') . \"\\n\";\n"; //Error reporting
echo "echo "echo \"Loaded Extensions: \";\n";
echo "foreach (php_ini_loaded_file() as $file) {\n";
echo " echo \"- $file\\n\";\n";
echo "}\n";
echo "echo "\n";
?>
";
Add your comment