I had solved how to load plugin css in Croogo CMS.
Simply add these,
in app/plugin/myplugin/views/helpers/myplugin.php
make sure you have declared
// As in Croogo documentation
// Home → Wiki → Developers → Plugins → Hooks
// To hook your plugin's ExampleHelper
// (at app/plugins/example/views/helpers/example.php)
// in ALL controllers:
Croogo::hookHelper('*', 'Myplugin.Myplugin');
Hope it helps, happy baking.
Simply add these,
in app/plugin/myplugin/views/helpers/myplugin.php
public function beforeRender() {and in app/plugin/myplugin/config/myplugin_bootstrap.php
if($this->Layout->View !== false)
{
$this->Layout->View->addScript($this->Html->css('/myplugin/css/myplugin'));
}
}
make sure you have declared
// As in Croogo documentation
// Home → Wiki → Developers → Plugins → Hooks
// To hook your plugin's ExampleHelper
// (at app/plugins/example/views/helpers/example.php)
// in ALL controllers:
Croogo::hookHelper('*', 'Myplugin.Myplugin');
Hope it helps, happy baking.
Comments