简体   繁体   中英

php_mcrypt extension for windows server 2008 R2

I found lots of articles about this problem, however none of them helped me.

Here is a I list of what I 've already tried:

  • uncomment the semicolon on php.ini
  • add the dependence file (libmcrypt.dll) on php folder, windows and windows/system32
  • I 've restarted the IIS Server after each attempt
  • I cannot use this method , it was installed with a zip file.

On IIS Manager the extension is shown as enabled but checking the php error log I found this message multiple times:

PHP Warning:  PHP Startup: Unable to load dynamic library 'C:\Program Files (x86)\PHP\v5.3\ext\php_mcrypt.dll' - %1 is not a valid Win32 application. in Unknown on line 0

Here is a the screenshot of phpinfo() phpinfo-mcrypt

I have Windows Server 2008 R2 64bit with IIS 7.5 and PHP 5.3.10. Maybe the file (php_mcrytp.dll) is not the good one, where can I download it? On php site I cannot find the php_mcrytp.dll file under ext folder.

Thank you

If you downloaded PHP for Windows from php.net and are running the FastCGI version of PHP (as you should with PHP 5.3.x and IIS), mcrypt library is already compiled statically in the PHP engine. You don't need to install any extra DLL.

If you see the mcrypt section in phpinfo's output then it means mcrypt is already enabled (otherwise the mcrypt section would be missing).

And that's also the reason there is no mcrypt DLL.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM