What is the phpinfo()?
Outputs large amounts of information about the current state of PHP. This includes information about PHP integration options and extensions, PHP version, server information and environment (if integrated as a module), PHP environment, OS version information, path, master and local values of configuration options, HTTP headers and PHP license.
Because each system is set up differently, phpinfo () is usually used to check configuration settings and predefined variables available on a given system.
phpinfo() is also a valuable debugging tool as it contains all EGPCS (environment, GET, POST, cookie, server) data.
How to create the PHPINFO file?
On the cPanel, you need to create a phpinfo.php file.
You can create a phpinfo.php file in the public_html or html folder. That file will appear with WordPress Files.
What is the use of phpinfo()?
The phpinfo() functions will appear all PHP configuration Information.
After creation phpinfo.php file, you need to add the below code in the phpinfo.php file.
<?php
echo phpinfo();
?>
How to run phpinfo.php file?