Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IIS: How to override some php.ini settings with a custom .ini file?

Tags:

php

iis

ini

Is it possible to load a custom .ini file that overrides the fat messy php.ini from the distribution package?

On unix systems I believe this can be achieved by putting additional ini files inside /etc/php.d but I'm not sure about IIS.

The question is pretty straightforward: Can I define an additional .ini file that adds or overloads the standard php.ini settings, for example:

php.ini is located in c:\windows and is the loaded configuration file. myphp.ini is my custom configuration

Where to put myphp.ini so that both php.ini and myphp.ini are loaded and myphp.ini is loaded after php.ini?

Is there a 'Scan this dir for additional .ini files ' under Windows?

like image 482
user1517081 Avatar asked Dec 19 '12 12:12

user1517081


Video Answer


1 Answers

Looks like this might give you an idea on how to have a custom php.ini: Enable Per-Site PHP Configuration on IIS 7 and IIS 6.0

Hope it helps.

like image 121
Skuli Axelson Avatar answered Nov 01 '22 16:11

Skuli Axelson