where oh where can my php.ini be?

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View

   Everything started with me wanting to write a little command line php
script that uses some gd functions. After a little research, I realized I
need to unccomment the line in my php.ini that references the gd module. I
did that, and still no gd (I get the error message at run time, that
imagecreatefromjpeg() doesn't exist). At first I thought that I changed the
wrong php.ini file, even though I changed the one in c:\windows, which is
the one php_info() says it's using. I then proceeded to delete every php.ini
file on my computer except the one in c:\windows (there was one more). Same
problem, no GD. Then just for fun I decided to rename the php.ini file in
c:\windows to php.bak. I then ran my script again thinking I would get an
error about a missing php.ini. To my dismay this was not the case, as I
received the same complaint about imagecreatefromjpeg() not existing. I'm
perplexed. There is absolutely no file named php.ini on my entire PC, much
less in c:\windows where it says it's looking for it. I've search through
hidden folders, and nothing.
    What is php using as the ini file? Basically, I need to get to the point
where php is using an ini file, of which I know exactly where this file is
and I can modify it. Can anyone shed some light on this for me?



Re: where oh where can my php.ini be?


Quoted text here. Click to load it

 Create a file containing just <?php phpinfo(); ?>.

 Then look near the top, and see what it says next to "Configuration File
(php.ini) Path". (And post that here exactly as it displays, if the php.ini
file it references doesn't seem to be being read)

<http://www.andyhsoftware.co.uk/space Space: disk usage analysis tool

Re: where oh where can my php.ini be?


Quoted text here. Click to load it

So you changed the right php.ini, you can trust in what phpinfo() says. ;)

Quoted text here. Click to load it

Have you restarted your webserver before running your script again?
If not, try to do that. You should always do a restart of your webserver,
after you have changed something in php.ini. Otherwise, your changes won't
have any effect.

kind regards,

Site Timeline