I
I
Ivan2016-01-11 09:06:17
mint
Ivan, 2016-01-11 09:06:17

How to make php work on linux?

Put LAMP on Linux Mint -
PhpMyAdmin works, localhost too
But when you try to create a folder with a site and access this site from a browser - it does not interpret it as a PHP script - in the source code it shows
<?php
echo('hi');
?>
That is, it perceives my test page not as Php but as an Html file.
How to fix

Answer the question

In order to leave comments, you need to log in

2 answer(s)
P
Puma Thailand, 2016-01-11
@opium

enable open short tag
or use <?php

S
Sergey Goncharenko, 2019-09-29
@sergeygsd

linux mint 18.2 suddenly doesn't work like yours. I looked in /etc/ for two php7 folders, almost empty. And php has php.ini. And for a long time. And in debian I didn't even think about it. Everything worked. Conclusion, do not believe, but look at typical configs where they lie, what is in them. And so no one will tell you.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question