Archive for the 'PHP' Category

Install PHP applications with WebMatrix

Microsoft has recently launched a beta release of a new project called WebMatrix. This is a complete web development stack that can be used to start developing and deploying web sites. One thing that may be not so obvious from all the existing announcements is the fact that WebMatrix has full support for installing, running and publishing PHP applications.

Here are the examples of how WebMatrix can be used to create and publish a PHP web site (using WordPress as a showcase). Continue Reading »

10 Comments »

ruslany on July 9th 2010 in PHP, WordPress

2,248 views

PoorFairAverageGoodExcellent (1 votes, average: 5.00 out of 5)

WinCache Extension 1.1 for PHP – Release to Web

Today IIS team has published the final release of WinCache Extension 1.1 for PHP. This is the latest stable and production ready version of the extension. The v1.1 has all the features available in version 1.0 plus the following features.

  • User Cache API’s can be used by PHP scripts to store PHP objects and variables in shared memory. This way PHP scripts may improve the execution speed by storing processed data in the cache and then using it in subsequent requests instead of re-creating the data on every request.
  • WinCache Session Handler can be used to configure PHP to store the session data in shared memory cache. Using shared memory instead of the default file session storage helps improve performance of PHP applications that store large amount of data in session objects. The content of the WinCache session cache is persisted on disk so that it is not lost during IIS worker process recycling.
  • File Change Notifications – the entries in the opcode and file caches are now updated as soon as the corresponding PHP files are modified on a file system. This is very useful for PHP applications that store its configuration in PHP files – for example Joomla!. Now the configuration changes for those applications take effect right away instead of a 30 seconds delay (default cache refresh interval).
  • Lock/Unlock API’s – these API’s can be used to obtain/release an exclusive lock on a key in the cache.

Install the Windows Cache Extension 1.1 for PHP – RTW

To install the WinCache Extension 1.1 for PHP 5.2 and PHP 5.3, use the download links at the extension’s home page at http://www.iis.net/expand/WinCacheForPhp. Continue Reading »

No Comments »

ruslany on June 30th 2010 in PHP, WinCache

1,664 views

PoorFairAverageGoodExcellent (3 votes, average: 4.67 out of 5)

WinCache Extension 1.1 for PHP – Beta 2

Today IIS team has published a second beta of WinCache 1.1, which has the following new features and improvements :

  • File Change Notifications – the entries in the opcode and file caches are now updated as soon as the corresponding PHP files are modified on a file system. This is very useful for PHP applications that store its configuration in PHP files – for example Joomla!. Now the configuration changes for those applications take effect right away instead of a 30 seconds delay (default cache refresh interval);
  • Persistent Session Handler – the content of the WinCache session cache is persisted on disk so that it is not lost during IIS worker process recycling.
  • Lock/Unlock API’s – these API’s can be used to obtain/release an exclusive lock on a key in the cache.

The beta builds of the extension can be downloaded and installed from the extension home page at: http://www.iis.net/expand/wincacheforphp (look for the “WinCache 1.1 – Beta 2” section there). The source code can be obtained from http://pecl.php.net/package/WinCache/1.1.0beta2. The documentation for the extension can be found on PHP.NET WinCache documentation.

To learn how to change popular PHP applications to use WinCache 1.1 features refer to the following:

This is the beta release and the WinCache team is looking for your feedback on new features and functionality. Use the WinCache Community Forum to ask questions about the extension, report bugs and problems and to suggest features and improvements.

No Comments »

ruslany on April 29th 2010 in PHP, WinCache

2,432 views

PoorFairAverageGoodExcellent (4 votes, average: 4.75 out of 5)

Slides and Questions from PHP on Windows Webcast

On April 9, Mark Brown and I did a PHP|Architect webcast “PHP Performance On Windows”. The slides from the presentation have been published at the following link:

PHP Performance on Windows – slides

There were a number of question at the end of the webcast that we did not get to answer due to lack of time. This blog post provides answers to those questions. Continue Reading »

2 Comments »

ruslany on April 13th 2010 in FastCGI, PHP, WinCache

2,004 views

PoorFairAverageGoodExcellent (4 votes, average: 5.00 out of 5)

PHP on IIS: MonitorChangesTo setting in FastCGI

PHP on Windows loads its configuration file php.ini during the startup of the process php-cgi.exe. When PHP is run on IIS via FastCGI the php-cgi.exe processes are re-used to handle many requests. If configuration settings in php.ini file get updated, those changes will not be picked up by php-cgi.exe processes until the processes are recycled or restarted by IIS FastCGI module. This means that any time you change the PHP configuration you have to manually recycle IIS Application Pools that use PHP. This post explains how to configure FastCGI in IIS so that PHP configuration changes take effect right away without the need to manually recycle or restart the IIS Application Pools. Continue Reading »

No Comments »

ruslany on March 30th 2010 in FastCGI, PHP

2,196 views

PoorFairAverageGoodExcellent (2 votes, average: 3.00 out of 5)

Make WordPress faster on IIS with WinCache 1.1

This post explains how to improve performance of WordPress on Windows by using the WinCache Extension 1.1 – Beta for PHP. You probably already know that just by enabling the WinCache extension and without any code changes it is possible to get a significant increase in WordPress performance – this is described in details in PHP on Windows: The WinCache 1.0 Benchmark. But this can be taken even further by using the user cache API’s available in WinCache 1.1 release. Continue Reading »

16 Comments »

ruslany on March 5th 2010 in PHP, WordPress

2,725 views

PoorFairAverageGoodExcellent (2 votes, average: 5.00 out of 5)

More Performance Improvements in WinCache 1.1

Since the WinCache Extension for PHP has been released last year it has been widely deployed by customers who run PHP on Windows OS and it has proven to provide a substantial performance boost for PHP applications hosted on Windows-based web servers.

Today IIS team has published a beta of WinCache 1.1, which provides more options for improving performance of PHP applications on Windows. Specifically, the new version includes :

  • User Cache API’s, that can be used by PHP scripts to store PHP objects and variables in shared memory. This way PHP scripts may improve the execution speed by storing processed data in the cache and then using it in subsequent requests instead of re-creating the data on every request. The addition of these API’s closes the remaining feature gap that WinCache had when compared with other similar caching solutions like APC and XCache.
  • WinCache Session Handler, that can be used to configure PHP to store the session data in shared memory cache. Using shared memory instead of the default file session storage helps improve performance of PHP applications that store large amount of data in session objects.

The beta builds of the extension can be downloaded and installed from the extension home page at: http://www.iis.net/expand/wincacheforphp (look for the “WinCache 1.1 – Beta” section there). The source code can be obtained from http://pecl.php.net/package/WinCache/1.1.0. The documentation for the extension can be found on PHP.NET WinCache documentation.

This is the beta release and the WinCache team is looking for your feedback on new features and functionality. Use the WinCache Community Forum to ask questions about the extension, report bugs and problems and to suggest features and improvements.

No Comments »

ruslany on March 4th 2010 in PHP

1,818 views

PoorFairAverageGoodExcellent (1 votes, average: 5.00 out of 5)

WinCache Extension 1.0.1 – Servicing Release

The new release of WinCache Extension for PHP - version 1.0.1 – is available for download. This is a servicing release that has fixes for bugs reported in v1.0. In particular the following fixes and changes have been made in this release:

  • Fixed require_once on PHP5.3. If the files were absolute and similar files were included in different case, require_once was including it twice.
  • Changed relative path cache to act as resolve path cache. Incremented refcounts under aplist lock. Did comparison using InterlockedCompareExchange.
  • Fixed crashes which were happening because aplist refcount and opcode cache refcount can get out of sync due to local cache.
  • Exposed is_local_cache property from ocache_fileinfo and fcache_fileinfo. Stats page will use this to indicate when local opcode data is shown.
  • Updated the wincache.php to pass chart data on query string to ensure that the charts show the same data that is displayed in tables
  • Updated the wincache.php to show whether information about a global or local cache instance is being displayed
  • Changed variable names and comments to indicate rplist is resolve path cache and not just relative path cache
  • Changed wincache.php to use resolve_path instead of relative_path

The new release is available for download from the extension’s home page at: http://www.iis.net/expand/wincacheforphp. The source code for the extension is available on PHP PECL page here: http://pecl.php.net/package/WinCache/1.0.1. The documenation for the extension can be found at http://www.php.net/manual/en/book.wincache.php.

No Comments »

ruslany on January 26th 2010 in PHP

2,453 views

PoorFairAverageGoodExcellent (2 votes, average: 5.00 out of 5)

Multiple PHP versions on the same IIS server

This post describes how to configure IIS to support multiple versions of PHP on the same server. This kind of setup is useful in development environments where it is necessary to test an application with different PHP versions. Also, it is often used in production environments, where many PHP applications are hosted on the same server and some of them have dependency on a particular PHP version.

In order to setup multiple versions of PHP side by side on the same IIS server it is necessary to install PHP manually by following the steps described in php.net documentation for IIS 5.1 and IIS 6.0 and for IIS 7.0 and later. Do not use PHP Windows installer because it does not support side by side installations. Continue Reading »

6 Comments »

ruslany on December 16th 2009 in FastCGI, PHP

3,970 views

PoorFairAverageGoodExcellent (4 votes, average: 4.00 out of 5)

WinCache Extension 1.0 for PHP – Release to Web

The Windows Cache Extension 1.0 for PHP – RTW is available for download. This is a final, production-ready release that is provided under an open source BSD license with the source code hosted and maintained on http://pecl.php.net/packages/wincache/.

Install the Windows Cache Extension 1.0 for PHP – RTW

To install the Windows Cache Extension for PHP 5.2 and PHP 5.3, use the download links at the extension’s home page at http://www.iis.net/expand/WinCacheForPhp.

The installation with Web Platform Installer is the easiest as it will automatically place the extension binary into proper location and will update the PHP configuration to enable the extension. Also, if you have the beta or RC release of the extension installed, then Web PI will upgrade it. If you install any PHP application by using Web PI then the Windows Cache Extension for PHP will be offered as an optional component. Continue Reading »

6 Comments »

ruslany on November 19th 2009 in PHP

2,433 views

PoorFairAverageGoodExcellent (3 votes, average: 3.67 out of 5)

Recently Published Articles