function fetchChoicesWithName($comboName) { /* Fetch choices info from the database given the combo name PARAM: # comboName - name of the combo for which the choices are to be fetched RESULT: # array of ComboChoice objects */ try { $a = Combochoice::find("all", array("conditions" => array("tblcombo.nameCombo=?", $comboName), "joins" => array("combo"))); } catch (Exception $e) { echo 'Caught exception: ', $e->getMessage(), "\n"; } return $a; }