How to create a phpinfo page
What is phpinfo.php?
A phpinfo.php file is a file that gives you information about your server configuration. It can also help you troubleshoot your server because it has information about other important settings in your server, many of which may help you figure out the causes of problems within your web server.
This file will not have information on the current version of your database scheme, but it does have the following useful data:
- PHP license
- PHP version
- HTTP headers
- PHP environment
- Information about PHP compilation options and extensions
- Server information and environment (if compiled as a module)
- OS version information, paths, master and local values of configuration options
As a debugging tool, phpinfo.php also contains all EGPCS data, which means the following data specifically:
How to create a phpinfo.php page
To create a phpinfo.php page in your web server, follow the steps below:
- Click on My Account at the top of the page.
- Select Hosting Manager from the drop-down menu.
- Enter your username and password, and click Log In.
- On the Home page, click the word Files or the [ v ] arrow symbol on the right side.
- Click the File Manager icon, which is next to the Directory Privacy icon.
- On the pop-up screen, select Web Root (public_html/www) and click Go.
- Next screen, all of the files and folders in your web space will be displayed in a tree-style directory. Make sure you are in the public_folder.
- On the top-left of the page, click File.
- Type in the filename, which is phpinfo.php, and click Create New File.
- Find the newly created phpinfo.php file and right-click on it.
- In the dropdown menu, click Edit.
- On the pop-up box, make sure the character encoding setting is utf-8 or ascii. Click Edit.
- Add the following code in the opened file:
< ?php phpinfo(); ?>
- Click Save Changes.
Note: When using the CLI (command line usage) mode, phpinfo() outputs are in plain text instead of HTML.
If you want to see the phpinfo.php file you just created, view it on your browser by typing the file's web address (url) in the browser address bar. If you placed it in the correct folder, the URL will be http://yourdomain.com/phpinfo.php.
Important Note: After you have the information you need, are done troubleshooting your server, or have accomplished any other purpose of the phpinfo.php file, it is recommended that you delete it from your server. You can also simply rename the file and/or move it to another directory.
These measures are all for security purposes. Malicious hackers could easily use this file to gather information about your server that might compromise your hosting account.
If you want to know how to change PHP versions, click here.
If you want to know how to use different PHP versions, click here.
If you want to know how to access the File Manager, click here.
Fantastic...Thank you for your feedback =)
Sorry... Please submit a support ticket or try another search.
- How to create full and partial backups of your Website files
- How to create Apache Handlers
- How to create custom Error Pages
- How to create a MySQL Database and User
- How to create a Subdomain