1. Installing the PHP memcache extension1). Download memcache extension Https://pecl.php.net/package/memcache Note: A. x86 or 64 bit depends on version B of Wamp server. PHP version 2). Copy to ext directory copy php_memcache.dll to ext directory 3). Modify php.ini add Extension=php_memcache.dll4). Restart Apache Service
2. Installing the Memcached service1). Download memcachedhttp://blog.couchbase.com/memcached-windows-64-bit-pre-release-available2). Install memcached Service A. Unzip the downloaded file to wamp/bin/memcached B. Run cmd.exec with the system administrator. Under Wamp/bin/memcached, run memcached-d installd. Start the service memcached-d start3). Test code
<?PHPHeader("Content-type:text/html;charset=utf-8");$memcache=NewMemcache;$memcache->connect ("127.0.0.1", 11211);Echo"Server S version:".$memcache->getversion (). "<br/>";$data=Array( ' url ' = ' http://iw3c.com ', ' name ' = ' The Tribe of ' Aries ');$memcache->set ("Key",$data, 0,10);EchoThe Store data in the cache (data would expire in seconds) <br/> ";Echo"Data from the cache:<br/>";Var_dump($memcache->get ("key"));
watch out. 1. Installing the Memcached service requires Cmd.exe to run 2 with the system administrator. Although it is a 64-bit system, WAMP is not necessarily a 64-bit
Install Memcache under Windows 7 and Wamp server