AnsweredAssumed Answered

Custom Web Publishing - php API

Question asked by mangiofazulli on Dec 5, 2017
Latest reply on Dec 5, 2017 by edwardlscott

we've got a Filemaker server 16 running in our local network. We've created a small fmPro application document-requests in order to manage and distribute our technical documentation. The document selection and download page document-requests.php was build using the Filemaker API for php. Our website for the document distribution is hosted on an Apache server in the same LAN as the Filemaker server.


- The Filemaker API for php is hosted in a folder called root/api in our Apache server

- The page document-requests.php for create, read, update and delete records works fine with the API for php


In the Filemaker layout is a field that triggers a script onObjectEnter in order to personalize the document name and publishing date by a find/replace placeholders. The scriptTrigger works with a Filemaker Client as expected, the new name and the date were replaced, and the resulting file is saved in the documents folder for downloads.

The script is compatible with custom web publishing.


- i've tried to call the script directly from the API after a setField() for each $_POST value (new name, publishing date ) with newPerformScriptCommand() but nothing happens, i get a $result (var_dump($result) ), and i do not get an error message.


I guess that it should be possible to execute the script by the API call regarding the fact that create, read update and delete works with the page document-requests.php? What could be wrong? Has the API for php to be hosted on the Filemaker server (web server)?


Thank you for your help,