Turning on PHP in Jaguar – Mac OS X 10.2

Thu, August 22nd 2002

PHP is installed on Jaguar as it was in previous OS X builds and only needs to be activated in order to work. Here’s how…

Launch Terminal.app and enter each of the following steps in order:

1. sudo apxs -e -a -n php4 /usr/libexec/httpd/libphp4.so

2. echo 'echo "AddType application/x-httpd-php .php" >> /etc/httpd/httpd.conf' | sudo sh -s

3. sudo apachectl restart

That should do it. To test if it’s running, create a files called info.php (or whatever) that consists of the text:
<?php phpinfo() ?>, drop it in your web site documents folder and open it in a browser. It should look something like this. If all is well, you now have an active PHP module with support for MySQL.

For a more detailed instructions and a PHP lib file with more features configured take a peek here.





No Comments »

RSS feed for comments on this post.

Leave a comment

*