Asked  7 Months ago    Answers:  5   Viewed   31 times

How to install memcache in WAMP?

I don't find any php_memche in php.ini.

What do I do now?


thanks for your step, now memcache enabled in WAMP, i have cross checked in the PHPINFO as well. memcache is displaying.

i have tried below example memcache sample. but throwing error.


$memcache = new Memcache;
$memcache->connect('localhost:8085', 11211) or die ("Could not connect");

$version = $memcache->getVersion();
echo "Server's version: ".$version."<br/>n";

$tmp_object = new stdClass;
$tmp_object->str_attr = 'test';
$tmp_object->int_attr = 123;

$memcache->set('key', $tmp_object, false, 10) or die ("Failed to save data at the server");
echo "Store data in the cache (data will expire in 10 seconds)<br/>n";

$get_result = $memcache->get('key');
echo "Data from the cache:<br/>n";



Getting below notice error.

( ! ) Notice: Memcache::getversion() [memcache.getversion]: Server localhost:8085 (tcp 11211) failed with: Malformed version string (0) in C:wampwwwmemcachesample.php on line 7

What i missed...



Here are the steps that worked for me:

Needed Files

  • memcached.exe Direct Link
  • MSVCP71.DLL Windows DLL Files
  • msvcr71.dll
  • php_memcache.dll Working memcache for PHP 5.3.4 OR REF


  1. Copy MSVCP71.DLL, msvcr71.dll to C:windowssysWOW64
  2. Copy memcached.exe into C:memcached
  3. Click Windows-Key
  4. Type: CMD
  5. press: Ctrl-Shift-Enter
  6. Choose yes
  7. type: C:memcachedmemcached.exe -d install
  8. type: C:memcachedmemcached.exe -d start
  9. Copy php_memcache.dll to C:wampbinphpphp5.3.4ext
  10. Restart Apache using Wamp controls
  11. Enable WAMP -> PHP -> PHP Extensions -> php_memcache
Wednesday, March 31, 2021
answered 7 Months ago

See the end of this post for how to do this in WAMPServer 3

For WampServer 2.5 and previous versions

WAMPServer is designed to be a single seat developers tool. Apache is therefore configure by default to only allow access from the PC running the server i.e. localhost or or ::1

But as it is a full version of Apache all you need is a little knowledge of the server you are using.

The simple ( hammer to crack a nut ) way is to use the 'Put Online' wampmanager menu option.

left click wampmanager icon -> Put Online

This however tells Apache it can accept connections from any ip address in the universe. That's not a problem as long as you have not port forwarded port 80 on your router, or never ever will attempt to in the future.

The more sensible way is to edit the httpd.conf file ( again using the wampmanager menu's ) and change the Apache access security manually.

left click wampmanager icon -> Apache -> httpd.conf

This launches the httpd.conf file in notepad.

Look for this section of this file

<Directory "d:/wamp/www">
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    # The Options directive is both complicated and important.  Please see
    # for more information.
    Options Indexes FollowSymLinks

    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   AllowOverride FileInfo AuthConfig Limit
    AllowOverride All

    # Controls who can get stuff from this server.
#    Require all granted
#   onlineoffline tag - don't remove
     Order Deny,Allow
     Deny from all
     Allow from
     Allow from ::1
     Allow from localhost

Now assuming your local network subnet uses the address range 192.168.0.?

Add this line after Allow from localhost

Allow from 192.168.0

This will tell Apache that it is allowed to be accessed from any ip address on that subnet. Of course you will need to check that your router is set to use the 192.168.0 range.

This is simply done by entering this command from a command window ipconfig and looking at the line labeled IPv4 Address. you then use the first 3 sections of the address you see in there.

For example if yours looked like this:-

IPv4 Address. . . . . . . . . . . :

You would use

Allow from 192.168.2

UPDATE for Apache 2.4 users

Of course if you are using Apache 2.4 the syntax for this has changed.

You should replace ALL of this section :

Order Deny,Allow
Deny from all
Allow from
Allow from ::1
Allow from localhost

With this, using the new Apache 2.4 syntax

Require local
Require ip 192.168.0

You should not just add this into httpd.conf it must be a replace.

For WAMPServer 3 and above

In WAMPServer 3 there is a Virtual Host defined by default. Therefore the above suggestions do not work. You no longer need to make ANY amendments to the httpd.conf file. You should leave it exactly as you find it.

Instead, leave the server OFFLINE as this funtionality is defunct and no longer works, which is why the Online/Offline menu has become optional and turned off by default.

Now you should edit the wampbinapacheapache{version}confextrahttpd-vhosts.conf file. In WAMPServer3.0.6 and above there is actually a menu that will open this file in your editor

left click wampmanager -> Apache -> httpd-vhost.conf

just like the one that has always existsed that edits your httpd.conf file.

It should look like this if you have not added any of your own Virtual Hosts

# Virtual Hosts

<VirtualHost *:80>
    ServerName localhost
    DocumentRoot c:/wamp/www
    <Directory  "c:/wamp/www/">
        Options +Indexes +FollowSymLinks +MultiViews
        AllowOverride All
        Require local

Now simply change the Require parameter to suite your needs EG

If you want to allow access from anywhere replace Require local with

Require all granted

If you want to be more specific and secure and only allow ip addresses within your subnet add access rights like this to allow any PC in your subnet

Require local
Require ip 192.168.1

Or to be even more specific

Require local
Require ip
Require ip
Tuesday, June 1, 2021
answered 5 Months ago

The steps are as follows :

  1. Close WAMP (if running)
  2. Navigate to WAMPbinphp(your version of php)
  3. Edit php.ini
  4. Search for curl, uncomment extension=php_curl.dll
  5. Navigate to WAMPbinApache(your version of apache)bin
  6. Edit php.ini
  7. Search for curl, uncomment extension=php_curl.dll
  8. Save both
  9. Restart WAMP
Wednesday, June 2, 2021
answered 5 Months ago

sadly this probably won't ever help anyone else who has this same problem, but I was able to get everything working by just changing the port to 465.

Monday, August 16, 2021
Justin Charles
answered 2 Months ago

I think there is some other installed languages on your system that caused this problem. However you can change phpMyAdmin inside its settings. To fix it, please do these steps (As you can't read the texts, I have to tell you an address in phpMyAdmin) :

This is for phpMyAdmin 3.4.5; You may have another version

  1. Open phpMyAdmin
  2. In the home page, look at the main menu in top of the page (right side)
  3. Point your mouse on the last item; A list will be shown to you, then click at the last item with a wrench icon beside it. (You entered to the phpMyAdmin settings)
  4. There are 4 boxes in the current page. Look at the right-bottom one. There is a button there. It's reset button. Click on it ...
  5. Your settings will reset and you can see phpMyAdmin in English language.

Good luck.

Monday, August 23, 2021
answered 2 Months ago
Only authorized users can answer the question. Please sign in first, or register a free account.
Not the answer you're looking for? Browse other questions tagged :