Jump to content

Problem's compiling PHP


Recommended Posts

So I compiled php from source on my Mac OS X 10.4.9 and I recieved no errors.  I added this to httpd.conf

AddType application/x-httpd-php .php

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

DirectoryIndex index.html index.php

and restarted apache2.  Whenever I visit a php page on my site, my broswer (safari) downloads the page as text.  Where did I go wrong?

Thanks!

Link to comment
Share on other sites

Did you add it as an Apache Module or CGI? You must either load it as an Apache module or CGI in order for your PHP code to be parsed, adding the lines you have added wont do anything untill you have loaded it into Apache. I find it easier to add it as an Apache Module just add a line like this to the httpd.conf:

LoadModule php5_module "/path/to/php/php5_apache2.so"

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.