News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Brian Swan's Blog:
Updating PHP Settings in Windows Azure
April 12, 2011 @ 08:46:43

Brian Swan has a new post today looking at how you can update some PHP settings in your Windows Azure instance - an alternative to redeploying your every time your php.ini file might need an update.

I came across this question on Twitter last week: "How can I turn display_errors on for an application that is running in Windows Azure?" I have to admit that I was stumped. The only thing I could think of was to re-deploy the application with an updated php.ini file. But, I happened to mention this question to Ben Lobaugh who suggested a very simple idea: Store your PHP settings in some durable store external to your application as key-value pairs, then loop through the settings and update them with the ini_set function when a page loads.

He puts a big disclaimer on his suggestion, noting that it's "a hack and only a hack" and can be useful for someone still learning how to work with Azure and deployment. He shows how to use a Table storage to save the values and make them easier for the application to grab at runtime. Using the tools from their SDK, fetching and setting those values is a simple process. An idea like this, while convenient, could potentially cause performance issues down the line, do be careful with this recommendation (and be sure to load test).

0 comments voice your opinion now!
windows azure settings phpini table storage


blog comments powered by Disqus

Similar Posts

Maarten Balliauw's Blog: Accessing ServiceConfiguration in FastCGI (PHP) web role

PHPWomen.org: Bundled go-pear.phar broken in 5.2 windows releases

Christopher Jones' Blog: Oracle Instant Client 10.2.0.4 for Mac OS X Intel x86 is Available

Brian Swan's Blog: Using the Windows Azure Tools for Eclipse with PHP

Christian Wenz's Blog: phpa-norl, a phpa port for Mac OS X and Windows


Community Events





Don't see your event here?
Let us know!


release api package podcast deployment laravel introduction framework symfony community unittest language update tips series interview library opinion zendserver install

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework