OSX Lion: Apache / PHP (start / stop)

Make the configuration file writable, sudo chmod 644 /etc/apache2/httpd.conf

Edit the file /etc/apache2/httpd.conf and uncomment the PHP module line (LoadModule php5_module libexec/apache2/libphp5.so) by removing the # character.

Add convenience start and stop alias to .bashrc, alias apache_start='sudo launchctl load -w /System/Library/LaunchDaemons/org.apache.httpd.plist' alias apache_stop='sudo launchctl unload -w /System/Library/LaunchDaemons/org.apache.httpd.plist'

Use the aliases accordingly apache_start or apache_stop from command line.