Question

Cannot load mcrypt extension. Please check your PHP configuration. XP IIS

Asked by: mindwarpltd

I get this error from PhpMyAdmin.

Cannot load mcrypt extension. Please check your PHP configuration.

I used the 'Microsoft Web Platform Installer' then I added the files and the entries to the INI

[PHP_MCRYPT]
extension=php_mcrypt.dll

I had previously tried the direct download and had the files and the INI values.

I've tried several things but just cant get rid of this error.

This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.

Subscribe now for full access to Experts Exchange and get

Instant Access to this Solution

  • Plus...
  • 30 Day FREE access, no risk, no obligation
  • Collaborate with the world's top tech experts
  • Unlimited access to our exclusive solution database
  • Never be left without tech help again

Subscribe Now

Asked On
2009-09-28 at 00:33:28ID24766107
Topics

PHP for Windows

,

PHP and Databases

,

PHP Installation

Participating Experts
4
Points
500
Comments
23

Trusted by hundreds of thousands everyday for fast, accurate and reliable tech support.

  • "The time we save is the biggest benefit of Experts Exchange to Warner Bros. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange." Mike Kapnisakis, Warner Bros.
  • "Our team likes having a resource that is more secure than just using Google and most experts using this service really know their stuff. It's nice to look here first versus using Google." Dayna Sellner, Lockheed Martin
  • "Anytime that I've been stumped with a problem, 9 out of 10 times Experts Exchange has either the accepted solution or an open discussion of the potential solution to the problem." Kenny Red, eBay Inc.

See what Experts Exchange can do for you.

Got a question?

We've got the answer.

Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.

Screenshot of Experts Exchange Knowledgebase

Need individual assistance?

Our experts are ready to help.

If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.

Screenshot of Experts Exchange Knowledgebase

Want to learn from the best?

Read articles from industry experts.

Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.

Screenshot of an Article

Working on a long term project?

Store your work and research.

Save solutions to your questions, answers you’ve discovered through searching plus helpful articles in your personal knowledgebase for easy future access.

Screenshot of Experts Exchange Knowledgebase

Access the answers to your technology questions today.

Subscribe Now

30-day free trial. Register in 60 seconds.

What Makes Experts Exchange Unique?

Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Trusted by the world's most respected brands.

image of each brand's logo

Faithfully serving IT professionals since 1996.

Experts Exchange Logo

Try it out and discover for yourself.

Subscribe Now

30-day free trial. Register in 60 seconds.

Related Solutions

  1. PHP and mcrypt problems
    I have made a successfull static installation of PHP 4.02 compiled with libmcrypt and mysql support, to apache 1.3.12. The problem is that I can't get it to work... How do I encrypt and decrypt a textstring successfully? My testscript looks like this: <html> <he...
  2. Cannot load mcrypt extension. Please check your PHP con…
    After I install phpmyadmin finish it warn me Cannot load mcrypt extension. Please check your PHP configuration. How can I fix the problem
  3. PHPMyAdmin 2.10.1 mcrypt extension error message.
    I am using PHPMyAdmin 2.10.1 installed on a Linux CENT OS 4 dedicated server. Everytime I access the PHPMyAdmin it gives me the error message "Cannot load mcrypt extension. Please check your PHP configuration". Any idea how I can configure PHP on the server in orde...

Free Tech Articles

  1. WARNING: 5 Reasons why you should NEVER fix a computer for free.
    It is in our nature to love the puzzle. We are obsessed. The lot of us. We love puzzles. We love the challenge. We thrive on finding the answer. We hate disarray. It bothers us deep in our soul. W...
  2. SCCM OSD Basic troubleshooting
    SCCM 2007 OSD is a fantastic way to deploy operating systems, however, like most things SCCM issues can sometimes be difficult to resolve due to the sheer volume of logs to sift through and the dispe...
  3. Migrate Small Business Server 2003 to Exchange 2010 and Windows 2008 R2
    This guide is intended to provide step by step instructions on how to migrate from Small Business Server 2003 to Windows 2008 R2 with Exchange 2010. For this migration to work you will need the fo...
  4. Create a Win7 Gadget
    This article shows you how to create a simple "Gadget" -- a sort of mini-application supported by Windows 7 and Vista. Gadgets can be dropped anywhere on the desktop to provide instant information, ...
  5. Outlook continually prompting for username and password
    There have been a lot of questions recently regarding Outlook prompting for a username and password whilst using Exchange 2007. There are a few reasons why this would happen and I will try to cover t...
  6. Backup Exchange 2010 Information Store using Windows Backup
    There seems to be quite a lot of confusion around the ability to backup Exchange 2010 using the built in Windows Backup feature. This stems from the omission of this feature prior to Exchange 2007 s...

Cloud Class Webinars

  1. Avoiding Bugs in Microsoft Access
    Alison Balter takes and in-depth look at avoiding bugs in Access. In this webinar you will learn about using the immediate window to debug your applications, invoking the debugger, using breakpoints to troubleshoot, stepping through code, setting the next statement to execute, ...
  2. Top 10 Best New Features in Visio 2010
    Scott Helmers gives live demonstrations of the top 10 new features in Visio 2010. This webinar will teach you how to create compelling diagrams by adding shapes to the page with a single click, linking the shapes in a diagram to data in Excel (or SQL Server, or SharePoint), ...
  3. IT Consultant Business Secrets Revealed
    Michael Munger, Experts Exchange tech pro and IT consultant, pulls back the curtain on his very successful businesses and answers question on every IT consultant and business owner should know about. He shares secrets on what he did to solve the 5 most common problems in IT, ...
  4. Disaster Recovery and Business Continuity
    Quest CTO, Mike Billon, gives an overview of the steps involved in building a dunamic disaster recovery plan. Through case studies and an examination of software/hardware tooles for monitoring and testing, you'll gain a better understandin of where you are, where you want ...
  5. Organize Your Visio Diagrams with Containers and Lists
    Scott Helmers uses cross functional flowcharts, wireframe diagrams, data graphic legends and seating charts to teach you: how to ustilize all three new structured diagram components in Visio 2010, the best practices for organizeing shapes in previous version of Visio, how to organize ...
  6. How to Us Objects, Properties, Events and Methods in Microsoft Access
    Alison Dalter gives an in-depbth look at objects, properties, events and methods in Microsoft Access. In this webinar you will learn about using the object browser, referring to objects, working with properties and methods, working with object variables, understanding the ...

Join the Community

Give a Little. Get a Lot.

Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.

Join the Community

Answers

 

by: thetmanvnPosted on 2009-09-28 at 00:48:29ID: 25437358

First, you need to tell us, which php suite or bundle you use and version, because there're different location of php.ini, and you must edit the right ones.

 

by: mindwarpltdPosted on 2009-09-28 at 01:08:22ID: 25437434

I used the 'Microsoft Web Platform Installer'

Its PHP Version 5.2.11 included in it, the previous standalone version I tried was also this version.

phpMyAdmin is version 3.2.2

My php.ini file is c:\Program Files\PHP\php.ini.

I use the link in the start menu to edit the file.

My PATH start with  c:\Program Files\PHP\;c:\Program Files\PHP\ext\;

 

by: thetmanvnPosted on 2009-09-28 at 01:16:54ID: 25437473

Ok, so please check these things:

1./ in php.ini: extension_dir = "C:\Program Files\PHP\ext" exist?

2./ in C:\Program Files\PHP\ext, is php_mcrypt.dll exist?

3./ Did you restart your web server after you edit the php.ini?

 

by: hernst42Posted on 2009-09-28 at 01:33:49ID: 25437547

To use mcrypt you need to install additional dlls on windows, which are not provided by the Windows installer of php
See http://www.php.net/manual/en/mcrypt.requirements.php

 

by: mindwarpltdPosted on 2009-09-28 at 01:45:44ID: 25437598

thetmanvn:

1. Yes
2. Yes
3. Yes. I used iisreset and I tried a reboot

hernst42: I have libmcrypt.dll

 

by: OutliverPosted on 2009-09-28 at 01:47:34ID: 25437605

maybe you'll have less problems when using xampp. Just take a look at this.

 

by: mindwarpltdPosted on 2009-09-28 at 01:49:55ID: 25437618

I need to use IIS

 

by: thetmanvnPosted on 2009-09-28 at 01:54:02ID: 25437636

Very strange here

Ok, try phpinfo() to check your output, to find more evidence, look out for mcrypt, my test result is below

mcrypt
mcrypt support      enabled
Version       2.5.7
Api No       20021217
Supported ciphers       cast-128 gost rijndael-128 twofish arcfour cast-256 loki97 rijndael-192 saferplus wake blowfish-compat des rijndael-256 serpent xtea blowfish enigma rc2 tripledes
Supported modes       cbc cfb ctr ecb ncfb nofb ofb stream

 

by: hernst42Posted on 2009-09-28 at 01:54:03ID: 25437637

Where did you place the libmcrypt.dll?
Did you use the correct version of libmcrypt?
Is the libmcrypr.dll readable by the IUSR_XXXXX?
You could monitor starting IIS with the FileMon and see which files are not loaded properly/are missing.

 

by: mindwarpltdPosted on 2009-09-28 at 02:02:04ID: 25437669

thetmanvn:

Mcrypt isn't showing at all in phpinfo

hernst42:

libmcrypt.dll is in C:\Program Files\PHP

>Is the libmcrypr.dll readable by the IUSR_XXXXX?
What ?

>You could monitor starting IIS with the FileMon and see which files are not loaded properly/are missing.
How do I do that ?

 

by: thetmanvnPosted on 2009-09-28 at 02:28:39ID: 25437772

>libmcrypt.dll is in C:\Program Files\PHP

I thought that file must be in "C:\Program Files\PHP\ext" ???

>Is the libmcrypr.dll readable by the IUSR_XXXXX?

For the test, you should give read permission to user IUSR_XXXXX (XXXXX is your Server Name) to ext folder (or all php folder)

>You could monitor starting IIS with the FileMon and see which files are not loaded properly/are missing.
Use filemon from sysinternal suite http://technet.microsoft.com/en-us/sysinternals/default.aspx
(It's very powerful and easy-using suite for Windows Adminstrator)


 

by: mindwarpltdPosted on 2009-09-28 at 02:43:57ID: 25437835

>For the test, you should give read permission to user IUSR_XXXXX (XXXXX is your Server Name) to ext folder (or all php folder)

How do i do that, the IIUSR is only a member of guest.
I went into users within computer management.

I've downloaded sysinternal suite, but it doesn't tell you where to put the files in the zip file and filemon isn't in the zip.

 

by: hernst42Posted on 2009-09-28 at 03:04:17ID: 25437904

>libmcrypt.dll is in C:\Program Files\PHP
should be in the system folder or any other folder that is available via $PATH

 

by: thetmanvnPosted on 2009-09-28 at 03:13:58ID: 25437956

@hernst42: No, for using with php, libmcrypt.dll must in the folder that was specified in extension_dir in php.ini.

@mindwarpltd: Right-Click on C:\Program Files\PHP, choose Properties -> Security Tab -> Add User IISUSR_XXXXX, and give he a read permission in permission panel.

>Filemon and Regmon End of Life on 9/1/09 Process Monitor is the replacement for Filemon and Regmon and is much more advanced and scalable than its predecessors.

Sorry, I didn't update sysinternal suite info. From Sep, 1st, Process Monitor (procmon.exe) is replace for Filemon and Regmon. The suite is zip file, you can extract anywhere and use directly.

 

by: thetmanvnPosted on 2009-09-28 at 03:18:01ID: 25437978

Ah, sorry,

libmcrypt.dll is in PHP Directory is correct. Noneed to be in System Folder, But php_mcrypt.dll must be in extension folder and must be enabled in php.ini (seem you've got it all).

 

by: mindwarpltdPosted on 2009-09-28 at 04:46:56ID: 25438373

>@mindwarpltd: Right-Click on C:\Program Files\PHP, choose Properties -> Security Tab -> Add User IISUSR_XXXXX, and give he a read permission in permission panel.

I don have a security tab, just sharing and web sharing, no where to add permissions.

So I just unzip the sysinternal zip and put them in a folder and put them on path ?

 

by: thetmanvnPosted on 2009-09-28 at 04:53:13ID: 25438426

Yeah, you can put it on PATH for convenience.

It seems you're using Windows XP???

Open Explorer -> Tools -> Folder option -> View -> Uncheck Use Simple Sharing in Advanced Setting Panel, then you will have security tab in Folder Properties.

Anyway, did phpinfo()  show you any extension was loaded?

 

by: mindwarpltdPosted on 2009-09-28 at 05:00:04ID: 25438481

I've downloaded SCESP4I.EXE and that given me the security tab.

However, I don't seem to have an IIS user, I thought I had earlier, I have...

IUSR_AARONSERVER - Internet Guest Account

IWAM_AARONSERVER - Launch IIS Process Account

Is it one of those ?

 

by: mindwarpltdPosted on 2009-09-28 at 05:01:42ID: 25438495

>It seems you're using Windows XP???
Yes XP Pro

>Anyway, did phpinfo()  show you any extension was loaded?
Yes it showed loads of extensions, but not mcrypt

 

by: mindwarpltdPosted on 2009-09-28 at 05:23:17ID: 25438662

Ahh its

IUSR_AARONSERVER

I've added Read & Execute, List Folder Contents and Read permission to the PHP folder.

I've used iisreset and phpinfo and still no mcrypt :(

 

by: thetmanvnPosted on 2009-09-28 at 05:30:27ID: 25438717

Use must use IIS, ok?

But before this can you test whether your application works normally with other bundle?

I prefer to xamplite, you can download here:

http://www.apachefriends.org/en/xampp-windows.html#646

Stop your IIS, and mysql if you have yours, or you can change Apache2 for preventing port conflicting. Just for test before go further, because, your config and installation seems correct.

Or you have another machines for testing, start from scratch, too see whether it works or not. I must go now, discuss with you later.

 

by: mindwarpltdPosted on 2009-09-28 at 05:54:05ID: 31634261

I was thinking, this has to be something with the mcrypt files I'm using.
Sure enough, although the files were the right version, the time was different 19:41 whereas all the others were 19:36.

So I ran the standalone install and its now working.
I did try this before, so I guess something we've been doing has help.

:)

 

by: kiettyyyyPosted on 2010-01-03 at 21:38:17ID: 26168662

Alright, this is how I fixed it.

If you attempt to add the mhash or mcrypt extension into your PHP.ini file manually after installing PHP via WPI, PHP won't recognize the mcrypt or mhash extension.

In order to get mcrypt working properly, you have to go into your Control Panel, Programs, find your PHP installation, hit "Change" or "Modify", find mcrypt from the list and have it install onto the disk. Restart your IIS instance.

Good luck! This worked perfect for me!

20120131-EE-VQP-002

3 Ways to Join

30-Day Free Trial

The Experts

98% positive feedback on 31,087 answers since March 2000. angeliii is a Microsoft Most Valuable Professional for his work with MS SQL Server & Develoment.

He has also proven his knowledge of Visual Basic Programming, PHP Scripting and Oracle Databases.

The Experts

97% positive feedback on 10,752 answers since July 2000. lrmoore has more than 18 years experience in the networking industry.

The six-time Mircosoft MVPs specialties include firewalls, virtual private networking, and network management.

Testimonials

"...and excellent source for support... Kind of like having your very own IT dept." Electriciansnet

Testimonials

"I was apprehensive at signing up at first. However... it has already made my life as an IT administrator much easier." JaCrews

Testimonials

"WOW! You guys have great, active, and knowledgeable people on here." moore50

Business Clients

Business Clients

In the Press

"If you’ve got a question... Experts Exchange can supply an answer.”

In the Press

"...an invaluable aid for both IT professionals and those who require tech support."

In the Press

"where IT professionals provide quick answers on just about any topic"

Business Account Plans

Loading Advertisement...