Newbies zinterest Posted September 13, 2013 Newbies Posted September 13, 2013 Hello, I am searching for a reference document that describes the FM PHP API. What would you all recommend? I have found bits and pieces, but not a good old fashioned, comprehensive reference document. The best I have found so far is from Jonathan Starks website: http://jonathanstark.com/fm/filemaker-api-for-php-documentation.php That is more of a 'table of contents' format, but it was helpful. My current problem: I am having a little difficulty executing a FM script from PHP. The general method I am trying is: $newPerformScript = $fm->newPerformScriptCommand($layoutName, $scriptName, ''); $result = $newPerformScript->execute(); (By the way, the actual FM script being executed has "Set Field' statements that assign a literal text string to the field.) Anyway, when I finish step 2 above, I get the following error: 5: Command is invalid (for example, a Set Field script step does not have a calculation specified) Of course the source could be any number of things. If I am taking t he wrong approach here, I would appreciate it if someone would point me in the right direction. Thanks very much! - Z
doughemi Posted September 13, 2013 Posted September 13, 2013 There IS no "good old fashioned, comprehensive reference document". The closest you can come is the FileMaker http://www.filemaker.com/support/product/docs/12/fms/fms12_cwp_php_en.pdf and the example files in the FileMaker Server/Examples/PHP directory (on your server in the Library folder). BTW, I could not duplicate your error message with the code you posted (having first properly defined $layoutName and $scriptName). Can you post the exact commands in your php script? You have checked the script by running it in FM successfully, right?
Newbies zinterest Posted September 13, 2013 Author Newbies Posted September 13, 2013 doughemi, Now, why didn't I think of that . . . You have checked the script by running it in FM successfully, right? I had a (stupid) problem with the script. With that cleared I am now able to move forward. I was able to run a few scripts. I have been referencing the FileMaker examples you recommended. Those are good. I just wish there was a more comprehensive set of examples. At least I can continue under my own power. Thanks very much for the help! - Z
Recommended Posts
This topic is 4344 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now