How to install mcrypt for PHP 7.2 and PHP 7.3 on Centos 7(cPanel)
how easy it is to install mcyrpt for PHP 7.2 and PHP 7.3 via Pecl for Easy Apache4 on Centos 7(cPanel).
PHP officially deprecated mcrypt as of PHP 7.1 and this causes issues for sites whos CMS still requires it but want to run later PHP versions. More about that official notice is here.
Mcrypt installation process
Install epel-release repoInstall libmycrpt and libmcrypt-devel rpms needed for the PHP extensions.Update all Pecl php versions.Install Mcrypt PHP extensions via Pecl for PHP72 and PHP73Restart Apache/Litespeed to activate the extensions
Install epel-release repo if you do not already have it installed
yum install epel-release
Install libmycrpt and libmcrypt-devel rpms needed for the PHP extensions.
yum install libmcrypt libmcrypt-devel
Update all Pecl php...