Apache-PHP

Ryan Schmidt ryandesign at macports.org
Wed Nov 1 17:23:07 PST 2006


On Nov 1, 2006, at 19:08, Mack Johnson wrote:

> i just installed Apache & PHP, is there anything els i should do  
> get this to work on my g4 os 10.4.8? i am just starting to learn  
> php and need these things working.

Well, you didn't tell us much. How did you install it? What isn't  
working? What have you tried so far?

You also didn't mention whether you're using Apache 1 or 2. I  
recommend Apache 2. You would install it this way:

sudo port install apache2
sudo port install php5 +apache2

These commands will each print out instructions at the end showing  
you how to complete the installation and activation.


The php5 port might possibly not tell you everything you need to do  
to activate it. If after doing the above php5 doesn't work, you may  
need to add these two lines to your httpd.conf file (that's /opt/ 
local/apache2/conf/httpd.conf) inside the "IfModule mime_module"  
section:

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

Save the file, restart Apache 2 ("sudo /opt/local/apache2/bin/ 
apachectl/graceful"), and php5 should then work.





More information about the macports-users mailing list