loading php.ini from folder where the exe is

Hi,

I have been researching all the ways to install php on IIS7 and I am now using the fastcgi from microsoft as recomended.

What I want is that the ini is loaded thats located in the same folder php-cgi.exe is.

I don't see how to do this on IIS7 other than to specify it in the applicationhost.config as documented by MS.

After reading
http://www.iis-aid.com/articles/how_to_guides/where_php_ini_is_loaded_from

I thought that be remocing the PHPRC env variable and remove any registrey keys (they were not present) he woul pick up the file in the "Current working directory". Thats the directory php-cgi.exe is located no?

Is this possible and what am I doing wrong?

Thanks for your help! Tom

Average rating
(0 votes)
Brashquido's picture

Location: Melbourne, Australia

Joined: Sep 2003

Send PM

Brashquido said:

Pretty sure current working directory wouldn't be relative to the php directory. I'd suggest you use the EnvironmentVars directive in the FastCGI config to set your PHPRC variable. I'll be creating some guides on this in the coming weeks.

----------------
Dominic Ryan
5 x Microsoft IIS MVP, MCSE, MCSA
IIS Aid owner/webmaster