Michael Accardo

NAME

PHP::Perlinfo - Clone of PHP's phpinfo function for Perl

SYNOPSIS

        use PHP::Perlinfo;

        perlinfo();

DESCRIPTION

This module outputs a large amount of information (only in HTML in this release) about the current state of Perl. So far, this includes information about Perl compilation options, the Perl version, server information and environment, OS version information, Perl modules, and the Perl License.

It is based on PHP's phpinfo function. Like other clones of PHP functions on CPAN, perlinfo attempts to mimic the PHP function is as many ways as possible. But, of course, there are some differences in the Perl version. These differences will be logged in future revisions.

PHP's phpinfo function is usually one of the first things a new PHP programmer learns. It is a very useful function for debugging and checking configuration settings. I expect that many users of this module will already know PHP's phpinfo. To familiarize yourself with phpinfo, you can google "phpinfo" and see the output for phpinfo in one of the many results. (I rather not provide a link that can go bad with the passage of time.)

You can also read the description of the original PHP version:

http://www.php.net/manual/en/function.phpinfo.php

OPTIONS

There are 6 options. More to come.

INFO_GENERAL

The configuration line, build date, Web Server, System and more.

INFO_LICENSE

Perl license information.

INFO_MODULES

Local modules, their version number and more.

INFO_VARIABLES

Shows all predefined variables from EGPCS (Environment, GET, POST, Cookie, Server). This is not fully implemented yet.

INFO_CREDITS

Shows the credits for Perl, listing the Perl pumpkings, developers, module authors, etc.

Note: This is equivalent to the default output of PHP's phpcredits function. Whereas PHP puts the credits information in a separate function, I have decided to include it in the info function for Perl.

INFO_ALL

Shows all of the above. This is the default value.

EXAMPLES

        # Show all information, defaults to INFO_ALL
        perlinfo();

        # Show only module information
        perlinfo(INFO_MODULES);

Other things you could try: email yourself the results. This is handy in debug situations or if you want to keep an eye on something. To change stylesheet settings you could tie a variable to STDOUT, put the output into that variable and do a regular expression substitution.

NOTES

Every effort has been made to ensure compatibility with older versions of Perl 5.

This is an early release of this module and it lacks many important features in the PHP version. These features are not hard to implement but finding the time to add them is. Help wanted! Please email me if you want to help out. Thanks.

AUTHOR

Mike Accardo <mikeaccardo@yahoo.com>

COPYRIGHT

   Copyright (c) 2004, Mike Accardo. All Rights Reserved.
 This module is free software. It may be used, redistributed
and/or modified under the terms of the Perl Artistic License.