hello guys l have installed php7 from this link
and this link too.
but when i try to run a Laravel based project there is an error coming up as follows
Mcrypt PHP extension required.
I tried to locate mcrypt.so and change the path in mycrpt.ini but i still get the same error i only get this error i Laravel projects
Had the same issue - PHP7 missing mcrypt.
This worked for me in Ubuntu Please try below commands.
sudo apt-get update
sudo apt-get install mcrypt php7.0-mcrypt
sudo apt-get upgrade
Then restarts apache
sudo service apache2 restart
Hope this commands helps!
First Check whether the mcrypt PHP module is present:
$ php -m | grep mcrypt
To install the mcrypt PHP module we first need to satisfy the following prerequisites:
sudo apt install php-dev libmcrypt-dev php-pear
Now we are ready to install mcrypt PHP module on our Ubuntu 18.04 system:
$ sudo pecl channel-update pecl.php.net
$ sudo pecl install mcrypt-1.0.1
Open the /etc/php/7.2/cli/php.ini file and insert:
extension=mcrypt.so
All done. When successful, checking for the presence of the mcrypt PHP module should produce the following output:
$ php -m | grep mcrypt
mcrypt
Then restarts apache
sudo service apache2 restart