Project

General

Profile

Check php information » History » Version 13

Neil Voss, 08/09/2011 10:59 AM

1 1 Amber Herold
h1. Check php information
2
3
Create the following info.php in your web server document root directory (/var/www/html on CentOS. /srv/www/htdocs on SuSE. You can find its location in httpd.conf mentioned above under the line starting DocumentRoot).
4
5
<pre>
6 13 Neil Voss
sudo nano /var/www/html/info.php
7
</pre>
8
9
<pre>
10 1 Amber Herold
<?php
11
phpinfo();
12
?>
13
</pre>
14
15 9 Amber Herold
Execute the following commands, using the appropriate path to your info.php file.
16
17 4 Neil Voss
<pre>
18 5 Neil Voss
sudo touch /var/www/html/info.php
19 6 Neil Voss
sudo chmod 666 /var/www/html/info.php
20
echo "<?php  phpinfo();  ?>" > /var/www/html/info.php
21 8 Neil Voss
sudo chmod 444 /var/www/html/info.php
22 4 Neil Voss
</pre>
23
24 7 Neil Voss
Visit this page at http://HOST.INSTITUTE.EDU/info.php or http://localhost/info.php
25 1 Amber Herold
26 10 Amber Herold
You will see comprehensive tables of php and apache information, including the location of the additional .ini files, extension, include path, and what extension is enabled.
27 1 Amber Herold
28 11 Amber Herold
Here is an example screen shot of the part of the info.php page that tells you where php.ini and other configuration files are. This information will be used while installing components of the Web Server.
29 1 Amber Herold
30
!http://emg.nysbc.org/software/leginon/images/images/phpini.png!
31 2 Amber Herold
32
33
______
34
35 12 Amber Herold
[[Install Apache Web Server|< Install Apache Web Server]] | [[Download Appion and Leginon Files|Download Appion and Leginon Files >]]
36 3 Amber Herold
37
______