Question

How can I enable mycrypt PHP library for wordpress?

Posted April 13, 2018 1.8k views
WordPress

So, I am switching to Digital Ocean today from Hostgator(please don’t hurt me for using Hostgator in 2018) I am setting up a (relatively) short term site while I test Digital Ocean, and learn to work without cpanel. I did a oneclick install for wordpress on my droplet, and began getting settled in to rebuild my old wordpress site page by page. (I am doing it this way because the old site has lots of flaws to doing a migration is not in my best interest longterm)

First plugin I try to install says it cannot be activated on the grounds that mycrypt PHP library must be enabled first. Can I do this with the oneclick install for wordpress? Or do I have to scrap my droplet and do a new one with ubuntu? I would much rather stick with the oneclick install if the choice is mine to make. But I can’t really progress without some of these plugins.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
2 answers

You can install the php-mcrypt library with:

sudo apt-get update;
sudo apt-get install php-mcrypt;

Hi, @Kaote

I managed to get this installed on my droplet using the following commands:

sudo yum install epel-release
sudo yum install libmcrypt-devel

If you are running the default PHP installation you will want to run the following command as well.

sudo yum install php-mcrypt

Also you will need to find which is your main php.ini file and add or uncomment the following line:

extension=mcrypt.so

Let me know how it goes.
Regards,
Alex

Submit an Answer