Reconfigure Apache2 server with PHP 7

It’s a quite common problem that we face when we try to work around apache server and php.
Suppose you have just reconfigured your apache 2. Next you find that your php 7 script is not working any more with your php and no script is executed properly.
What will you do?

Open your linux terminal and type the following commands one after another. Usually
it works.

sudo apt-get install apache2 php7.0 libapache2-mod-php7.0

a2query -m php7.0

sudo a2enmod php7.0

sudo service apache2 restart

This article was written by ss

Sanjib Sinha is an Author, and Full Stack Web Developer.

He writes stories; as well as codes. His book “The Beginning Ethical Hacking with Python” (Apress) has been one of the most downloaded IT books in 2016-17 (Provided by Bookmetrix). Know his journey as a writer: http://sanjibsinha.com.

He loves to connect through his social media handle: @sanjibsinha.

Leave a Reply

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