©
This document uses PHP Chinese website manual Release
The installation package for WinCache includes a PHP script, wincache.php, that can be used to obtain cache information and statistics.
If the WinCache extension was installed via the Microsoft Web Platform Installer, then this script is located in %SystemDrive%\Program Files\IIS\Windows Cache for PHP\. On a 64-bit version of the Windows Server operating system, the script is located in %SystemDrive%\Program Files (x86)\IIS\Windows Cache for PHP. If the extension was installed manually, then the wincache.php will be located in the same folder from which the content of the installation package was extracted.
To use wincache.php, copy it into a root folder of a Web site or into any subfolder. To protect the script, open it in any text editor and replace the values for USERNAME and PASSWORD constants. If any other IIS authentication is enabled on the server, then follow the instructions in the comments:
Example #1 Authentication configuration for wincache.php
<?php
define ( 'USE_AUTHENTICATION' , 1 );
define ( 'USERNAME' , 'wincache' );
define ( 'PASSWORD' , 'wincache' );
$user_allowed = array( 'DOMAIN\user1' , 'DOMAIN\user2' , 'DOMAIN\user3' );
?>
Note: Always protect the wincache.php script by using either the built-in authentication or the server's authentication mechanism. Leaving this script unprotected may compromise the security of your web application and web server.