If you have the contents of a web page in a user directory, for example:
/home/*/public_html
Then you need to enable them, disable by default:
# Running PHP scripts in user directories is disabled by default # # To re-enable PHP in user directories comment the following lines # (from <IfModule ...> to </IfModule>.) Do NOT set it to On as it # prevents .htaccess files from disabling it. <IfModule mod_userdir.c> <Directory /home/*/public_html> php_admin_flag engine Off </Directory> </IfModule>
Just comment out this piece of code located in the file:
/etc/apache2/mods-enabled/php7.3.conf
Correct the path and file name on your system, version of PHP, etc.
source share