Ad Widget

Collapse

Apache2 Not Serving PHP :-(

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • skaffen
    Junior Member
    • Mar 2007
    • 2

    #1

    Apache2 Not Serving PHP :-(

    Hi there

    I'm new to Zabbix and still getting to grips with Linux...I've just done a clean build of Ubuntu 6.10 server and am installing Zabbix. I've got to the test point and when I try to access the web site, it says:

    You have chosen to open <blank>
    which is a: application/x-httpd-php
    from http://zabbix

    What should Firefox do with this file?


    Same thing happens in IE7, it's trying to download the php file to me...

    I've spent a few hours Goggling around, and my best guess is Apache2 isn't loading the php module(s) ?

    I've changed apache2.conf and added

    AddType application/x-httpd-php .php
    AddType application/x-httpd-php-source .phps
    AddHandler application/x-httpd-php5 .php

    but where do I tell it to load the php module? Or am I barking up the wrong tree?

    Help! :-)
  • kevlatimer
    Junior Member
    • Mar 2007
    • 1

    #2
    Bit of a gotcha on Debian based apache2 packages - may or not be the cause here.

    The apache2 package by default installs the apache2-mpm-worker package, which is a threaded implementation of apache. The PHP packages don't seem to be compiled thread-safe so you need the preforking model. Just issue an apt-get apache2-mpm-prefork and it'll sort itself out.

    This may or may not be the case on Ubuntu, I've not used it as a webserver before.

    Comment

    • Arthur
      Member
      • May 2006
      • 31

      #3
      Hallo skaffen,

      pls check


      it look like you missed the libapache2-mod-php5

      rgds
      /Arthur

      Comment

      • skaffen
        Junior Member
        • Mar 2007
        • 2

        #4
        PHP is working, I can view .php and .php5 in IE7 now. Still can't get Firefox to work with .php5, it still wants to download the file...

        My big problem is http://zabbix/~zabbix comes up blank in IE7, in Firefox it still wants to download the page as a file...

        Any more ideas for me to try? I'm contemplating starting from scratch again...

        Comment

        Working...