For that you need to understand Filemaker-PHP API. You can host your Filemaker application in Filemaker server. From Filemaker server Admin console you can start studying accessing this via Filemaker PHP site assistant. This will take you a tour of how to access and use of Filamer app via PHP. Documentation is there and you can follow the steps how to host the Filemaker application in Filemaker server, how to access FMP app in PHP via Custom Web Publishing engine of Filemaker server.
You need to go through the details of those.
An alternative to the Filemaker API is the FX Web API located here : http://www.iviking.org/FX.php/
We have used this for about 8 years, across Filemaker server versions from 7 through 12.
From this site:
"FX.php™ is a PHP class that pulls data from FileMaker Pro using the XML output by Server Advanced (for FileMaker 7) or the Web Companion (for FileMaker 5/6). From there, you can use PHP's diverse and powerful functions along side FX.php™ to manipulate your data, publish it on the internet, write changes back to FileMaker, and so on. FX is free and open-source."