PHP Info

There often comes a time when you need to check which modules are installed in PHP, see how it is configured, etc. The following PHP script can prove useful:

phpinfo.php:

     <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
     <html>
     <head>
     <title>PHP Info</title>
     </head>
     <body>
     <script language="php">
     phpinfo();
     </script>
     </body>
     </html>

If you install this script in one of your HTML directories, you can enter its URL in your browser to get a nicely formatted display of all of the PHP information. Note that you may not want to put this script in a top-level directory where the world's bad guys can easily find it by probing because it may reveal information that can assist them in cracking into your system. It may be wise to either give the script a name that's non-obvious or put it in some secret directory that only you know about.