mcrypt()This is a platform to work with different encryption algorithms in PHP
Enabling mcrypt setting inside PHP.INIInside your php.ini file search for the line
Change this line to
Loading the extensionInside your php extension directory ( where all other extension dll files are stored) your dll file should be there . like this
If it is not there then you have to install the extension. Go to control panel
Control Panel > Programs > Programs and Features
Uninstall or change a program
Select PHP and go for Change
Checking php installationWe can use phpinfo() function to know the settings of our PHP installation. If mcrypt is available then we will get this while using phpinfo() .
For Linux or LAMPAdd the extension by adding this line.
After this you have to restart your web server.
Checking extension status and functionWe can use function_exists() to check of mycrypt functions are available or not. Similarly we can check status of extension by using extension_loaded(). Here is a sample code to know the status of mcrypt support in your PHP installation.
The output of above code will tell about the mrypt support in our PHP installation.