diff --git a/search2/search/fieldRegistry.inc.php b/search2/search/fieldRegistry.inc.php index f46e514..6b36450 100644 --- a/search2/search/fieldRegistry.inc.php +++ b/search2/search/fieldRegistry.inc.php @@ -5,7 +5,7 @@ * KnowledgeTree Community Edition * Document Management Made Simple * Copyright (C) 2008, 2009, 2010 KnowledgeTree Inc. - * + * * * This program is free software; you can redistribute it and/or modify it under * the terms of the GNU General Public License version 3 as published by the @@ -249,37 +249,37 @@ class ExprFieldRegistry } } closedir($dir); - + // register any search fields tied to specific plugins - $this->registerPluginSearchFields(); + //$this->registerPluginSearchFields(); $this->registerMetdataFields(); } - + /** * Registers search fields which are specific to a certain plugin which may or may not exist/be active in the user's installation - * + * * NOTE this may only be used with commercial plugins? * NOTE do we want to restrict based on whether the plugin is active? it may have been deactivated but existing metadata created * while it was active would still exist and be searchable. The plugin should not need to be active to use the search. - * + * * SQL alter table plugin_helper ADD searchfields varchar(32) NULL Default NULL; - * + * */ private function registerPluginSearchFields() { // check the database for any registered plugin specific search criteria $pluginSearchCriteria = null; - + $result = DBUtil::getResultArray('Select h.pathname FROM plugin_helper h INNER JOIN plugins p ON (p.namespace = h.plugin) ' . 'WHERE p.disabled = 0 AND h.classtype = "search_criteria"'); if (PEAR::isError($result)) { return; } - + foreach ($result as $pluginSearchResult) { $fieldPath = KT_DIR . DIRECTORY_SEPARATOR . $pluginSearchResult['pathname']; - + // loop through those found and include from the plugin path $dir = opendir($fieldPath); while (($file = readdir($dir)) !== false) {