Sometimes, you need to have a local PHP web server available for previewing your project. Of course, you could use MAMP therefore, but most of the time (when you do not need .htaccess rules for example) it is sufficient to use the local PHP web server, which is inbuilt in Mac OSX.
Here are the simple steps to do that.
Export your whole project to a local folder of your choice. This could be a folder on your desktop, or a subfolder in your documents folder. I am using always a Sites folder in my users home directory.
2) Open terminal and enter there php -S localhost:8080 -t ~/Sites. This will tell the inbuilt PHP functionality to start a server under localhost:8080, and the document root will be /Users/your username/Sites. ~ (Alt + n) is a shortcut for your home directory.
3) Open a browser and navigate to http://localhost:8080. That's all, you should see your project.