Sunday, June 19, 2016

How to install PHP Mcrypt on Lubuntu 16.04


The php mcrypt module is one of the most important module on php for encryption, some of the major php framework are relying on this module, such as laravel.

To install mcrypt module on lubuntu 16.04, simply open your terminal/ command prompt/ console and then run this command:

sudo apt-get install php7.0-mcrypt 

If you are think we are done here, then you are absolutely wrong, just by installing the mcrypt package doesn't mean it will work, you need to do something else.

You need to run phpenmod command to add the mcrypt module, on php5 we use php5enmod command, but since we are using php7 we just use phpenmod, like this:

sudo phpenmod mcrypt

Next, you need to reboot your apache web server, so that the changes can take effect and mcrypt module is actually working.

sudo service apache2 restart

No comments:

Post a Comment