Test your website against PHP 7.0 for Linux /Mac users
Posted by Anders . on 2017-04-11 10:07

This is a guide that shows how you can test your website to the new version of PHP 7 which was installed 2017-04-12


Here is a guide how to test your webpage so that it works on our Linux server environment with PHP version 7.0. This guide is for you who is running Linux or Mac locally on the computer you're testing from.


1. First, open up a console window or terminal window.


On Mac: Go to Finder - Applications - Write in the search field


Copy the following row, except the quotes and paste in the terminal window:


"sudo cp / etc / hosts /etc/hosts.minbackup"


-Press Enter


-Enter your password for your user account if prompted.


Replace and against your own domain in the following line, and copy the entire line except the quotes. Then paste it into the terminal window:

"sudo echo >> / etc / hosts"


NOTE! Mac users must run the following command:


sudo - sh -c "echo >> / etc / hosts"


Press Enter


2: Open a web browser and visit your website to make sure that everything works as it should.


3: Go back to the terminal window and paste the following without quotes:


"sudo cp /etc/hosts.minbackup / etc / hosts"


Press Enter