pluginspath)) { if ($handle = opendir($CONFIG->pluginspath)) { while ($mod = readdir($handle)) { if (!in_array($mod,array('.','..','.svn','CVS')) && is_dir($CONFIG->pluginspath . "/" . $mod)) { if (!@include($CONFIG->pluginspath . $mod . "/start.php")) throw new PluginException("{$mod} is a misconfigured plugin."); if (is_dir($CONFIG->pluginspath . $mod . "/views/default")) { autoregister_views("",$CONFIG->pluginspath . $mod . "/views/default",$CONFIG->pluginspath . $mod . "/views/"); } } } } } } /** * @class PluginException * A plugin Exception, thrown when an Exception occurs relating to the plugin mechanism. Subclass for specific plugin Exceptions. */ class PluginException extends Exception {} ?>