How to create a phpinfo.php page

You can use a phpinfo page to view the current PHP information for your server.

This file outputs a large amount of information, including information about PHP compilation options and extensions, the PHP version, server information and environment (if compiled as a module), the PHP environment, OS version information, paths, master and local values of configuration options, HTTP headers, and the PHP License.

Because every system is set up differently, phpinfo() is commonly used to check PHP configuration settings and for available predefined variables on your particular system.

phpinfo() is also a valuable debugging tool, as it contains all EGPCS (Environment, GET, POST, Cookie, and Server) data.

 

To create a phpinfo file, open a plain text file, add the following lines, and save as phpinfo.php


<?php

phpinfo();

?>

 

Upload the file to the server. You should upload your file to the exact directory you want to test. Typically, this will be your html (/home/00000/domains/example.com/html/) directory, although you can upload it to any subdirectory on your server as well. Use FTP to upload the file.


Visit the page in your browser. If you uploaded it to your html directory, you should now visit http://www.example.com/phpinfo.php, replacing example.com with your own domain name.


Now you can view all of the information about PHP for your server for that particular directory.

  • 770 משתמשים שמצאו מאמר זה מועיל
?האם התשובה שקיבלתם הייתה מועילה

מאמרים קשורים

Internal server error with 777 chmodded folders and files

For PHP applications to access MySQL databases or upload (write) files to site folder(s), the...

Can I host adult content on your web hosting?

Yes, as long as it's legal adult material (no child porn or weird things).

Can you install a script on my account?

Yes, we can install any standard script for a one time fee of 15$. Most scripts can be...

Can you transfer my website from my old web hosting company?

For us to be able to move your website from your old web hosting company we will need the...

Do you do backups?

Yes, daily on all shared and reseller accounts! Vps and dedicated server's backups are client's...