Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

php.ini won't take effect

Status
Not open for further replies.

molly2ka

Programmer
Mar 20, 2004
27
US
Hi,

i've changed thinhs in the php.ini file located in windows directory on windows xp and i'v tried stopping, restarting apache, restarting the pc but php just won't take any notice of my changes. I make sure the changes are saved. Any ideas anyone? I once changed something on the file and it took ages to take effect I'm not sure what triggered it but I'm baffled.

Manni
 
Are you changing the right php.ini file? I have several scattered on my computer for various reasons.

- - picklefish - -
Why is everyone in this forum responding to me as picklefish?
 
the one in C:/WINDOWS. is that the right one??? there's also one in the php folder but I didn't think that would matter.

manni
 
rename one and restart apache .. if it whines like a pig, you know which one to edit :)

______________________________________________________________________
There's no present like the time, they say. - Henry's Cat.
 
PHP can tell you which file its using.

Create a script on your web browser which reads
Code:
<?php
phpinfo();
?>

Point your web browser at the script and search the returned HTML for the string "Configuration File (php.ini) Path"

The value to the right of the string is the php.ini file PHP is reading

Want the best answers? Ask the best questions!

TANSTAAFL!!
 
Ok, now this is scary. I'm starting to believe in voodoo [afro]

phpinfo() tells me that the Configuration File (php.ini) Path is C:\WINDOWS

I renamed the php.ini file to php.hide so now there isn't a php.ini file in my windows folder.

Apache restarts smoothly, the phpinfo() test script works (and still claims to use C:\WINDOWS\php.ini)

Env:
Win XP Pro
Apache 2.0
PHP 4.3.0
 

OK, found it.
The problem was in my httpd.conf file - my PHPIniDir settings was incorrect.

no voodoo after all.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top