These forums are locked and archived, but all topics have been migrated to the new forum. You can search for this topic on the new forum: Search for [SOLVED] php files downloading rather than displaying on the new forum.
Hi all
I have recently installed VirtualBox and phpVirtualBox on my system and now no sites will display. Instead it tries to download the pages. Could someone please tell me which file I need to look at to get them to display again correctly. I have checked a lot of other sites and followed their guides but most are aimed at php5 and not php7.
Any help greatly appreciated.
Chris: Adelphia Interactive
Desktop: Windows 10 Pro x64
Server: Ubuntu 16.0.4.2LTS
Webmin/Virtualmin: Latest (daily updates)
OK, I've resolved the issue. The issue was caused by the installation of VirtualBox and / or phpVirtualBox changing a setting in the mods-enabled/php7.0.conf file.
Before:
<FilesMatch ".+\.ph(p[3457]?|t|tml)$">
SetHandler application/x-httpd-php
</FilesMatch>
After (the fix):
<FilesMatch ".+\.ph(p[3457]?|t|tml)$">
#SetHandler application/x-httpd-php
</FilesMatch>
Chris: Adelphia Interactive
Desktop: Windows 10 Pro x64
Server: Ubuntu 16.0.4.2LTS
Webmin/Virtualmin: Latest (daily updates)
Worked! Thanks a lot!
Any file extension that downloads instead of executing needs a mime type - in days of old you had to set up many mime types just so you could play a mp3 or avi
Worked! But after the change dont forget to: 1) restart apache 2) clean browser cash
OK. Where's the "unsubscribe" button? I'm trying to not receive any further comments as the topic is marked as SOLVED.
Chris: Adelphia Interactive
Desktop: Windows 10 Pro x64
Server: Ubuntu 16.0.4.2LTS
Webmin/Virtualmin: Latest (daily updates)