Answer the question
In order to leave comments, you need to log in
Opens index.php as text (code)?
I uploaded the file via FTP, now it has the following rights: -rw-r--r-- 1 1003 1003 158 Apr 21 10:20 index.php
When opened in a browser, it is not interpreted, but the entire code of the file is displayed. What and where should be configured? I have a virtual one which is VirtualHost *: 80 but I access the ip address directly, it is only written in the Apache config:
<Directory /home/web/>
Options Indexes FollowSymLinks
AllowOverride None
Require all granted
</Directory>
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot /home/www
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Answer the question
In order to leave comments, you need to log in
I have not created a virtual host because it does not exist - it does not exist because you did not create it.
Create and you will be happy. Manuals for creating hosts on localhost - more
Let's start in order:
sudo a2enmod userdir
sudo adduser $USER www-data
sudo service apache2 reload
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question