Deprecated
SearchController object methods are deprecated, we recommend using Search API instead.
Returns search fields related to all fields or only the specified one.
Syntax
var fields = srch.getSearchFields(fieldName);
Arguments
fieldName
the name of the field. Example: 'Make'. This argument may be omitted.
Return value
If the argument is specified: returns the array of search fields related to the specified field.
If the argument is not specified: returns the array of search fields related to all fields.
Example
Get an array of SearchField objects for the Make field using the JavaScript OnLoad event:
var srch = pageObj.getSearchController();
var field = srch.getSearchFields('Make');
for(var i=0; i<field.length; i++){
// do something with SearchField objects
}
See also:
•JavaScript API: SearchField object
•JavaScript API: SearchController object (deprecated)