apache2 php not executed

Solution 1:

You need to choose between mpm_worker vs mpm_prefork (or mpm_event). Only one Apache MPM module. Try:

sudo a2dismod mpm_worker
sudo a2enmod mpm_prefork
sudo systemctl restart apache2.service

Take a look at this excellent answer at Serverfault.