Installing PHP 5.3 on Microsoft IIS
Update: This article is considered outdated. I’ve started an IIS Tutorial Series on how to install PHP and FastCGI on IIS 6.0.
With the release of PHP 5.3.0 introducing a lot of new features and bug fixes, it also comes in with a lot of changes for Microsoft IIS users. The biggest one of them is the way that PHP is now installed on IIS. The PHP 5.3 package now no longer provides an ISAPI DLL file (which I’ve been using). The only way to do it is through CGI, in which you should (have to?) use the FastCGI module. Depending on which version of IIS you have, the setup will be different. (I have IIS 6.0 on a Windows 2003 server). Microsoft seems to have gotten more close with Zend recently and provided better support on IIS that they even have a dedicated website for installing PHP on IIS and providing community support. Everything you need to know for installing PHP on IIS is on that website. PHP also now have a website dedicated to supporting PHP on Windows, regardless of whether you’re using IIS or Apache on Windows.
One of the big drawbacks I’ve found was that PHP decided to remove the MS SQL Server connection driver in the PHP 5.3 package. Just adding back in the DLLs from the old PHP packages back in the PHP directory did not work for me. Not only did they make it harder for IIS users to install PHP, they had to make it harder for those to connect to MS SQL Server. Upon doing some online searches, the driver used in PHP was very old (which explains my post on trying to get it to work properly on previous versions of PHP). Microsoft now has it’s own version of MS SQL Server driver (2005 and above) for PHP. I have yet to install it, but it would have to be done on a development environment to redo any code using PHP’s old connection library. I’ve also yet to find any documentation on it so I’m not sure of the details of the driver.
Update: September 24, 2009
Maybeme compiled a php_mssql.dll that works in the VC9 version of PHP 5.3. Note that the ntwdblib.dll files is still necessary. I haven’t gotten it to work personally, but it seems others have, so I’m sharing it for others who wants to try.
Download here: php_mssql.dll (right-click > Save Link As…)