windows - php_memcache.dll - for PHP 5.4

2019-01-30 06:51发布

I am borrowing the similar thread that wasn't helpfull for me: php_memcache.dll for PHP 5.3

I setup a server using the latest version of easyPHP for Windows. With it came PHP 5.4. I'm now looking for a memcache.dll file that worked for me before and I get this error

"PHP Startup: memcache: Unable t initialize module. Module compiled with module API=20090626 PHP compiled with module api=20100525 These options need to match"

Any links to a PHP 5.4 memcache.dll file would be greatly appreciated.

In the mentioned thread they adressed version for 5.3 and pierre, but there I find only an older version of the dll

5条回答
一夜七次
2楼-- · 2019-01-30 07:05

Any pecl modules that have officially been compiled for windows you find under http://windows.php.net/downloads/pecl/releases/

  • You need to know what php version you are running ie: 5.3,5.4,5.5 and so on

  • You need to know if your php version is 32 or 64 ie x86, x64

  • You need to know if the php version was compiled as thread safe or not ie:ts,nts

All the information you can get from a file with the following content

    <?php phpinfo() 

and view it from the webserver or from the command line sending the output to a file with:

    php -i > phpinfo.txt

NOTE: from the command line you get the data for php-cli witch most likely was compiled with the same configuration

And note that there is Memcache and Memcached but from the php website only memcache is available

查看更多
Rolldiameter
3楼-- · 2019-01-30 07:13

Thanks Kevin Horst, tested and working on my Win7 box !

The solution : just download the statically compiled version hosted on Amazon AWS, and extract.

Here is some output from php -i :

phpinfo()
PHP Version => 5.4.0

System => Windows NT xxxx 6.1 build 7601 (Windows 7 Ultimate Edition Service Pack 1) i586
Build Date => Mar  7 2012 14:17:27
Compiler => MSVC9 (Visual C++ 2008)
Architecture => x86
Configure Command => cscript /nologo configure.js  "--enable-cli" "--enable-memcache=shared"
Server API => Command Line Interface
Virtual Directory Support => enabled
Configuration File (php.ini) Path => C:\Windows
Loaded Configuration File => C:\Users\xxxx\Downloads\UniServer\usr\local\php\php.ini
Scan this dir for additional .ini files => (none)
Additional .ini files parsed => (none)
PHP API => 20100412
PHP Extension => 20100525
Zend Extension => 220100525
Zend Extension Build => API220100525,TS,VC9
PHP Extension Build => API20100525,TS,VC9

memcache

memcache support => enabled
Active persistent connections => 0
Version => 2.2.5
Revision => $Revision: 319585 $
查看更多
Viruses.
4楼-- · 2019-01-30 07:18

I found this link and it worked for me:

php_memcache-3.0.8-5.4-ts-vc9-x86.zip

Or you can browse a list of the latest releases here and find an applicable version:

http://windows.php.net/downloads/pecl/releases/memcache/

查看更多
Explosion°爆炸
6楼-- · 2019-01-30 07:30

The link is dead try http://windows.php.net/downloads/pecl/releases/memcache/

You'll find the latest memcache dll release in there. What you need to know before downloading:

-The OS version (32 or 64 bit)

-The PHP Compiler version

-Thread Safe support

The PHP Compiler version and thread safe support can be easily checked using the phpinfo() function

查看更多
登录 后发表回答