This functions enable you to get a lot of information about PHP itself, e.g. runtime configuration, loaded extensions, version and much more. You'll also find functions to set options for your running PHP. The probably best known function of PHP - phpinfo() - can be found here.
The constants below are always available as part of the PHP core.
Table 1. Pre-defined phpcredits() constants
Constant | Description |
---|---|
CREDITS_ALL | All the credits, equivalent to using: CREDITS_DOCS + CREDITS_GENERAL + CREDITS_GROUP + CREDITS_MODULES + CREDITS_FULLPAGE. It generates a complete stand-alone HTML page with the appropriate tags. |
CREDITS_DOCS | The credits for the documentation team |
CREDITS_FULLPAGE | Usually used in combination with the other flags. Indicates that the a complete stand-alone HTML page needs to be printed including the information indicated by the other flags. |
CREDITS_GENERAL | General credits: Language design and concept, PHP 4.0 authors and SAPI module. |
CREDITS_GROUP | A list of the core developers |
CREDITS_MODULES | A list of the extension modules for PHP, and their authors |
CREDITS_SAPI | A list of the server API modules for PHP, and their authors |
Table 2. phpinfo() constants
Constant | Value | Description |
---|---|---|
INFO_GENERAL | 1 | The configuration line, php.ini location, build date, Web Server, System and more. |
INFO_CREDITS | 2 | PHP 4 Credits. See also phpcredits(). |
INFO_CONFIGURATION | 4 | Current Local and Master values for php directives. See also ini_get(). |
INFO_MODULES | 8 | Loaded modules and their respective settings. |
INFO_ENVIRONMENT | 16 | Environment Variable information that's also available in $_ENV. |
INFO_VARIABLES | 32 | Shows all predefined variables from EGPCS (Environment, GET, POST, Cookie, Server). |
INFO_LICENSE | 64 | PHP License information. See also the license faq. |
INFO_ALL | -1 | Shows all of the above. This is the default value. |