Well it depends on the Linux distribution you are using, the version of php and the way you install it with Apache web server. Php.ini may be here:
Anyway, you can always find any file named php.ini in this manner
find / -name php.ini
The simplest yet most powerful usage of the renowned find command. By its help I was able to locate the php.ini on my Ubuntu 9.04 Apache2 and PHP5:
Use phpinfo() to find out
Write a simple PHP file with the following content:
And upload it to your server and access it in your web browser to get a page like this:
You should also read:
- Linux: How to open and extract an RAR zipped file and unrar the archive?
- PHP: open_basedir in php.ini to Restrict and Limit PHP File Accesses to a Certain Directory
- CSS: How to write CSS rules to detect or target Chrome, Safari or Opera browsers only?
- What is this Linux command?
- How to execute / run PHP scripts in the background?