set apache php version code example Example: get apache php version sudo a2dismod php5 sudo a2enmod php7.0