3

I've just updated the OS to version 16.04 and now php scripts don't get executed, I've just got the source code back. How can I enable php on 16.04?

I've try to call this command:

sudo a2enmod php7.0

but got error:

ERROR: Module php7.0 does not exist!

And I can't find php7 in synaptics, I can run php from command line and it's version PHP 7.0.4-7ubuntu2

Thomas Ward
  • 78,878
jcubic
  • 914
  • 6
  • 16
  • 31

1 Answers1

3

The package you need is libapache2-mod-php7.0 (or more importantly, use libapache2-mod-php, as this will link to the latest PHP version automatically from the repos)

This will install the PHP module and dependencies for it into Apache and your system. Make sure you have the latest repository data too (sudo apt-get update in the terminal) and any relevant security updates.

Thomas Ward
  • 78,878