Apache is downloading php files instead of displaying them

后端 未结 26 1095
陌清茗
陌清茗 2020-11-22 01:03

OS and server information:

  • CentOS 6.4 (Final)
  • Apache 2.2.15
  • PHP 5.5.1

I previously had php 5.3.x installed but decided to upgr

相关标签:
26条回答
  • 2020-11-22 01:52

    I had the same problem after using zypper rm php* to uninstall PHP and installing it again with zypper in php7 php7-gd php7-gettext php7-mbstring php7-mysql php7-pear

    I solved it by enabling the apache2 module and restarting the webserver:

    a2enmod php7 && service apache2 restart
    
    0 讨论(0)
  • 2020-11-22 01:54

    I had this problem. It turned out that I had both nginx and apache installed and automatically starting on boot. The problem was that nginx was binding to the http port first which prevented apache from starting.

    0 讨论(0)
提交回复
热议问题