Jump to content


Photo

php.ini file is in c:\winnt directory but no such directory exists!


  • Please log in to reply
1 reply to this topic

#1 neumanngroup

neumanngroup
  • New Members
  • Pip
  • Newbie
  • 1 posts

Posted 09 October 2006 - 03:48 PM

Hello,

When I run the phpinfo file on my website: http://www.neumanngr...com/phpinfo.php it says my php configuration file is located in c:\winnt.  There is no winnt directory on the computer hosting my site.

I do my own hosting and I am running Windows XP.  When I search for any php.ini file on my machine, the results come back with only the php-dist and php-recommended files inside the /php directory.  I know that one of these files is not being used because when I can some parameters on these files and restart apache, the parameters are not reflected in the phpinfo file.  I am searching with all files showing, all hidden files showing, and all system files and directories showing.

How can PHP even run without a valid .ini file?  Where is this file?  I have restarted Apache and the computer.  All I am trying to do is change the max_upload size in my .ini file and that is it.

Any thoughts on where I might find my missing .ini file??  Even though my site works great and is using a ton of PHP files (like wordpress and gallery2).

Thanks,

Eric...


#2 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 09 October 2006 - 06:07 PM

If php cannot find a php.ini file it'll use the defualt settings which is builtin to the intepreter. In order to get a php.ini file you'll want to rename php.ini-recommended to just php.ini. Now move php.ini to C:\windows (change C to the letter fo your hard drive).

Restart Apache and phpinfo should now reflect the changes you make to the php.ini

NOTE: If you are using Apache2.0.x or greater you can add the following:
PHPIniDir "C:/WINDOWS/"
To the httpd.conf file.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users