http://radio.weblogs.com/0100490/2002/11/11.html Enabling PHP on OS X.... I've been looking at various ways to manage a big pile of web content w/all the fancy linking, etc, for the purposes of providing a developer support site. In doing so, I came across the need to enable PHP on my development box so I could play around with the Fink site source. Searching Google revealed a bunch of hints, but they mostly seemed out of date. Here is the recipe I settled on. Works for me. I make no claim on being a PHP expert. In the apache configuration file /etc/httpd/httpd.conf, uncomment the lines that load the PHP module... ... LoadModule php4_module libexec/httpd/libphp4.so ... ... AddModule mod_php4.c ... ... and add these three lines... AddType application/x-httpd-php .php AddType application/x-httpd-php-source .phps DirectoryIndex index.php index.shtml index.html ... to the block. Mine looks like... # # This should be changed to whatever you set DocumentRoot to. # # # This may also be "None", "All", or any combination of "Indexes", # "Includes", "FollowSymLinks", "ExecCGI", or "MultiViews". # # Note that "MultiViews" must be named *explicitly* --- "Options All" # doesn't give it to you. # Options Indexes FollowSymLinks MultiViews # # This controls which options the .htaccess files in directories can # override. Can also be "All", or any combination of "Options", "FileInfo", # "AuthConfig", and "Limit" # AllowOverride None # # Controls who can get stuff from this server. # Order allow,deny Allow from all AddType application/x-httpd-php .php AddType application/x-httpd-php-source .phps DirectoryIndex index.php index.shtml index.html Make sure you restart apache (toggle web sharing in the sharing preferences pane). You can check to make sure apache restarted correctly by looking at the end of the file /var/log/httpd/error_log. That file will also contain any error messages that may have been spewed if something is misconfigured. To test, drop the string into the file foo.php in /Library/WebServer/Documents/ and then load http://localhost/foo.php. It should show you a big page of PHP configuration information. If it doesn't, something is broken.