I tried everything and searched everywhere.
I'm following this guide: https://www.digitalocean.com/community/tutorials/how-to-install-linux-nginx-mysql-php-lemp-stack-on-ubuntu-20-04
My config file:
server {
listen 80;
server_name your_domain www.your_domain;
root /var/www/your_domain;
index index.html index.htm index.php;
location / {
try_files $uri $uri/ =404;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock;
}
location ~ /\.ht {
deny all;
}
}
I created a info.php file. When I visit mydomain.com/info.php it download the file instead of executing it. Already cleared browser cache, also in NGINX.
systemctl status php7.4-fpm.service
then have a look at the log files.