where is the php.ini

garrett_44

Registered
Hi again

Hi do i find out via the terminal where the php.ini is thats being used by the version of php that is running? i seem to have several on my system in different folders such as

/usr/local/php/
/usr/lib/php/
/etc/

a+
gar
 
Open each in pico, check the versions they list (if you can find it), and compare that to what you get with phpinfo().
 
Hi there..
I needed to turn on Register Globals, so
I found my php.ini.default file, was found at the path
that the phpinfo() sent me to --> /etc
so, I edited it and restarted apache...
but the globals still don't seem to be registered because my little introduction to variables example isn't working.

from what I've said, does it sound like i edited the right file ???
I was expecting to edit a file named php.ini
(not php.ini.default)

could someone tell me why I'm not finding the php.ini file where phpinfo() says it should be ????

thanks !! :)
 
I tried figuring this our but never could... I'm convinced something about Apple's default Apache/PHP configuration simply ignores php.ini.

But I'm sure someone here will correct me if this is wrong.
 
I figured it out !! there *is* no php.ini file unless you create one... the php.ini.default is used

so... i just took the default file, edited it.. and saved it back to that folder as php.ini

now everything works the way i want it to.. I guess 10.3 apache looks for php.ini and if it doesn't find it uses the default config... hehe.. i bet that is in httpd.conf file somewhere.. ????
 
to be sure.... run phpinfo() and it will tell you the exact path of your php.ini (even if you don't really have one) hehhe
 
Back
Top