How to change php 7.0 to php 5.6 Ubuntu 16.04

Step 1

Disable php 7.0 in Apache

a2dismod php7.0

Step 2

Enable php 5.6 in Apache

a2enmod php5.6

Step 3

Restart Apache

service apache2 restart

Step 4

Enable php 5.6 in command line

update-alternatives --set php /usr/bin/php5.6 
update-alternatives --set phar /usr/bin/phar5.6 
update-alternatives --set phar.phar /usr/bin/phar.phar5.6

Leave a Reply

Your email address will not be published. Required fields are marked *