I'm having some diffuculties using the newPerformScriptCommand in my php-script. I'm trying to pass the search criterion that the user enters in af form field as a variable called $Search, but somehow it dosen't seem to reach the FM script as I get this respons from print($result): Find criteria are empty
The script goes like this:
/* This script performs a search in the "Varer" table using FM Quick Find */
$Search = trim($_REQUEST['Search']);
$fm = new FileMaker();
$fm->setProperty("database", "My Fashion Room");
$newPerformScript = $fm->newPerformScriptCommand("Varer", "QuickFind vare", $Search);
$result = $newPerformScript->execute();
In FM I have this simple script:
Perform Quick Find [$Search] with full script privileges set.
Can anyone figure out, what I am doing wrong?