Skip to main content

WonderCMS
WonderCMS
5 followers
2 questions
5 posts

Do you have questions about WonderCMS?

Log in to ask questions about WonderCMS publicly or anonymously.

How to add custom CSS and JavaScript to your WonderCMS powered website using plugin

As default WonderCMS has a built-in hooks used for creating plugins, Each hook has it's own use.

$Wcms->addListener('page', 'yourFunctionName'); // attach your function to the page 

This hook is used for additional content to defined page

$Wcms->addListener('js', 'yourFunctionName'); // can... (More)

You and everyone using WonderCMS can link back to WonderCMS site for appreciation by using a plugin called PoweredBy2 (by @shoaiyb sysa6)

 

Listeners/hooks are used for creating plugins

Creating a plugin

  • Your plugin folder must reside in the plugins folder (example.com/plugins/plugin-name).
  • IMPORTANT: plugin-name.php must have the same name as the plugin folder name.
    • For example, if your plugin folder name is plugin-name, then the... (More)