Doubt with PHP and Apache

8

I formatted my machine and was advised to use Linux, and so I did. But in my localhost , the .php files are not read / recognized, only the .html files.

I installed, reinstalled and did everything I saw on the internet, but without success.

    
asked by anonymous 12.05.2015 / 20:01

3 answers

0

I have resolved. My problem was with permissions, I gave a "$ sudo chmod 777 / var / www" in the terminal and it worked!

    
13.05.2015 / 15:42
5

I recommend following a tutorial for configuring PHP, Apache and MySQL (if you want) in linux. You have this Digital Ocean Tutorial , which I always use when I need it.

    
12.05.2015 / 20:11
3

If you are using Ubuntu or a derivative you could use the command below where you leave your lamp 100% functional:

sudo apt-get install lamp-server^
    
12.05.2015 / 20:44