New in PHP from version 5.4.x is a built-in web server perfect for use during development. By issuing the following command in a terminal you will be able to serve the content in ~/public_html over port 8080:
$ php -S 0.0.0.0:8080 -t ~/public_html
A more comprehensive article on the subject can be found at the php.net-site: Built-in web server.
On a side note you should remember that the built-in server is PHP specific, i.e. functionality like e.g.. the Apache .htaccess-file will not work since the built-in server isn’t an Apache server.