php.ini settings not registering
Moderator: General Moderators
php.ini settings not registering
Any changes I make to the php.ini file don't make the slightest change with my actual php configuration. I've restarted IIS, and even rebooted my server.
For example: I set SMTP = mail.mydomainname.com, and smtp_port = 2525, but everytime I use the mail() function, it tries to connect to localhost port 25 and fails.
I've also set it not to display error messages as output and to create a log file instead, but it doesn't do either.
Again, after making these changes, I restart IIS, and I've even rebooted my server once.
Any thoughts?
For example: I set SMTP = mail.mydomainname.com, and smtp_port = 2525, but everytime I use the mail() function, it tries to connect to localhost port 25 and fails.
I've also set it not to display error messages as output and to create a log file instead, but it doesn't do either.
Again, after making these changes, I restart IIS, and I've even rebooted my server once.
Any thoughts?
- superdezign
- DevNet Master
- Posts: 4135
- Joined: Sat Jan 20, 2007 11:06 pm
Re: php.ini settings not registering
You are likely editing the wrong file. Run phpinfo() and tell us what it says about the configuration path, and the loaded configuration file.freaknut wrote:Any thoughts?
- stereofrog
- Forum Contributor
- Posts: 386
- Joined: Mon Dec 04, 2006 6:10 am
http://www.php.net/manual/en/configuration.php explains where php expects to find php.ini and how you can change the default location.
I went through that list and didn't find any registry keys (I installed with a .zip file...I'm assuming that's why), so I went ahead and added HKEY_LOCAL_MACHINE\SOFTWARE\PHP\5.2.3\IniFilePath, but it's still not finding the right directory.
I don't know if I'm adding the key right.
EDIT*Does it make a difference if I installed php with the executable first, but then uninstalled it from add/remove programs?
I don't know if I'm adding the key right.
EDIT*Does it make a difference if I installed php with the executable first, but then uninstalled it from add/remove programs?
- superdezign
- DevNet Master
- Posts: 4135
- Joined: Sat Jan 20, 2007 11:06 pm
The registry key never worked for me. Apache 2.2 has a PHPIniDir directive, and it was the only method that worked for me. Maybe you should see if IIS has something similar.freaknut wrote:I went through that list and didn't find any registry keys (I installed with a .zip file...I'm assuming that's why), so I went ahead and added HKEY_LOCAL_MACHINE\SOFTWARE\PHP\5.2.3\IniFilePath, but it's still not finding the right directory.
I don't know if I'm adding the key right.
Umm... I'm 90% sure PHP doesn't work that way. Do you mean the package you used, i.e. XAMPP?freaknut wrote:EDIT*Does it make a difference if I installed php with the executable first, but then uninstalled it from add/remove programs?
On http://us3.php.net/downloads.php there is an installer. It's a .msi. I'm not sure why I downloaded that one first, but after running the install, I uninstalled it through Add/Remove programs and proceeded to install it properly using the .zip file.
- superdezign
- DevNet Master
- Posts: 4135
- Joined: Sat Jan 20, 2007 11:06 pm
Interesting. I guess they've tried to simplify the process too much.freaknut wrote:On http://us3.php.net/downloads.php there is an installer. It's a .msi. I'm not sure why I downloaded that one first, but after running the install, I uninstalled it through Add/Remove programs and proceeded to install it properly using the .zip file.
Hmm. Nothing seems to solve my issue.
I did the following as well as added a registry key, but to no avail:
http://www.php.net/manual/en/faq.instal ... .addtopath
http://www.php.net/manual/en/faq.instal ... tion.phprc
I'm still crawling google looking for an answer. Hope I find one soon. I don't like the idea of putting half my php files in the windows folder.
I did the following as well as added a registry key, but to no avail:
http://www.php.net/manual/en/faq.instal ... .addtopath
http://www.php.net/manual/en/faq.instal ... tion.phprc
I'm still crawling google looking for an answer. Hope I find one soon. I don't like the idea of putting half my php files in the windows folder.
- superdezign
- DevNet Master
- Posts: 4135
- Joined: Sat Jan 20, 2007 11:06 pm
Firstly, I'm pretty sure that php.ini is the only file that you'd need to put in there. Secondly, it's Windows... What do you expect? The WINDOWS folder is where it all happens.freaknut wrote:I'm still crawling google looking for an answer. Hope I find one soon. I don't like the idea of putting half my php files in the windows folder.