/** * Initialize the object by picking up and processing the config xml file */ public function init() { parent::init(); // facets $facets = $this->xml->xpath("//config[@name='facet_fields']/facet"); if ($facets !== false) { foreach ($facets as $facet) { $this->facets[(string) $facet["internal"]] = $facet; } } // (fixed) search limits $limits = $this->xml->xpath("//config[@name='limit_search_options']/facet"); if ($limits !== false) { foreach ($limits as $limit) { $this->limits[(string) $limit["internal"]] = $limit; } } // fields $fields = $this->xml->xpath("//config[@name='basic_search_fields']/field"); if ($fields !== false) { foreach ($fields as $field) { $this->fields[(string) $field["internal"]] = (string) $field["public"]; } } }
/** * Initialize the object by picking up and processing the config xml file * * @exception will throw exception if no configuration file can be found */ public function init() { parent::init(); // get group information out of config.xml too // we just store actual simplexml elements in the // $this->usergroups array. $groups = $this->xml->configuration->groups->group; if ($groups != false) { foreach ($groups as $group) { $id = (string) $group["id"]; $this->usergroups[Parser::strtoupper($id)] = $group; //case insensitive } } }