Full Stack LAMP - MEAN Developer, Python developer. Certified Azure Developer. Freelance programmer/consultant/trainer.

YII – The mcrypt PHP extension is not installed.

Recently I tried to install YII2 but I got “The mcrypt PHP extension is not installed.” error.

In this post, I will show you how to fix this issue and show you how to install mcrypt.

What’s mcrypt?

MCrypt is a replacement for the old crypt() package and crypt(1) command, with extensions. It allows developers to use a wide range of encryption functions, without making drastic changes to their code. It allows users to encrypt files or data streams without having to be cryptographers.

I am using suing ubuntu, below are the commands for installing mcrypt. Open your terminal and run the commands.

# install php module called php5-mcrypt 
$ sudo apt-get install php5-mcrypt
# enable mcrypt module 
$ sudo php5enmod mcrypt
# restart service 
$sudo service apache2 restart 

That’s it.

I hope you like this Post, Please feel free to comment below, your suggestion and problems if you face - we are here to solve your problems.

0 0 votes
Article Rating
Notify of

1 Comment
Most Voted
Newest Oldest
Inline Feedbacks
View all comments