To enable php
1) open terminal
2) cd /etc/
3) sudo cp php.ini.default php.ini
4) cd /private/etc/apache2/
5) sudo nano httpd.config
6) uncomment the two modules: php5_module and fastcgi_module. They were at line 114 and 115 for me.
7) Use ctrl and o to save
8) reload apache (can be done from system preferences).
Awesome! That worked great! So, how do I get MySQL working?:
Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2)
Found the answer on another forum. For anyone else having trouble, here's the solution:
you need to do the following in terminal.app when safe_mysql is running.
sudo mkdir /var/mysql/
sudo ln -s /tmp/mysql.sock /var/mysql/mysql.sock
Then restart apache.
php_value mysql.default_socket /tmp/mysql.sock