/** * Return array of all activated plugins * * @param none * @return array */ static function getNamesFromDB() { $names = array(); $plugins = Plugins::findAll(array()); // findAll if (is_array($plugins)) { foreach ($plugins as $plugin) { $names[] = $plugin->getName(); } // foreach } // if return $names; }
public function __construct($params = array()) { $conf = Config::getInstance(); $resources = new Resources(); Plugins::dispatchAll("resources", $resources); foreach ($conf->get("scripts", array()) as $script) { $resources->add($script); } foreach (Plugins::findAll("www/app") as $dir) { $resources->addDir($dir); } $params["scripts"] = $resources->getScripts(); $params["stylesheets"] = $resources->getStylesheets(); parent::__construct($params); }