September 22, 201114 yr Newbies I am having difficulty getting value lists to display on my website using the getValueList function. I have followed the formats I found in various forums and blogs. I can get the arrays that are intermediates in the calculation to prints but I cannot get the final results. I have tried two different methods listed below neither giving success. I have also tried to get value lists generated from field summaries and from customized lists. Neither works. What am I missing? The code follows below. I read in a forum that the get getValueList broke in Filemaker 10 and was replaced by getValueListTwoFields. I tried this and it was no better. I am currently using Filemaker 11. Method looking up a stored list. <?php require_once 'fmview.php'; require_once 'FileMaker.php'; require_once 'error.php'; $cgi = new CGI(); $cgi->storeFile(); $databaseName = 'Species'; $layoutName = 'web'; $fm = & new FileMaker(); $fm->setProperty('database', $databaseName); $fm->setProperty('username', 'pass'); $fm->setProperty('password', 'pass'); ExitOnError($fm); $layoutObject = $fm->getLayout($layoutName); ExitOnError($layoutObject); $valueList = $layoutObject->getValueList('Genus'); ?> The other approach uses $fieldObject = $layoutObject -> getField('Genus'); $valueList = $fieldObject -> getValueList(); In the HTML section I then run <?php print_r($valueList); echo 'message'; ?> Only 'message' is loaded on the screen when the page loads.
September 22, 201114 yr Automatic message This topic has been moved from "The Presentation Layer → Web Viewer" to "FileMaker and WEB 2.0 Technology → PHP → FileMaker PHP API".
Create an account or sign in to comment