how to serve with php code example Example: simple localhost php 1) cd ~/public_html 2) php -S localhost:8000