b2evolution b2evolution

  • Sign in
  • Sign up
  • About
  • Downloads
  • Hosting
  • Docs
  • Support
  • Sign in
  • Sign up
  • Manuals Home
  • Latest Updates
 
  1. b2evolution CMS User Manual
  2. Developer Reference
  3. Plugins
  4. Plugin development
  5. How to turn plugins on/off

How to turn plugins on/off

This refers to b2evolution version 0.9.0

All the plugins are stored in subfolders of the /plugins folder.

As of version 0.9.0, there are two types of plugins: the toolbar plugins that display on the post edit screen, and the renderer plugins that act as filters when displaying pots. Each type has its own subfolder.

How to enable/disable a plugin

The easiest way to completely disable a renderer plugin is to delete the corresponding .php file from the appropriate plugins subfolder. (This does not work for toolbar plugins in version 0.9.0)

To disable a toolbar plugin, open the file /b2evocore/_class_toolbars and look for:

	function display()
	{
		$this->init();	// Init if not done yet.

		$this->index_Plugins['b2evQTag']->display();
		$this->index_Plugins['b2evSmil']->display();
	}	

Delete (or comment out) the line for the plugin you don't want. b2evQTag is for the QuickTags. b2evSmil is for the smileys toolbar.

Plugin parameters

If you want to act with a little more control, just open the plugin .php file in a text editor and look for the following settings...

Toolbar plugins

priority

This controls the relative order in which the toolbar will be displayed. Example:

var $priority = 30;

Renderer plugins

priority

This controls the relative order in which the renderer will be applied to the post text. Example:

var $priority = 30;
apply-when

This controls when the renderer should be applied.

Possible values are:

  • 'stealth' (renderer will always apply and the post authors won't even know; plugin will be invisible but active)
  • 'always' (aka 'forced': renderer will always apply and the post author won't be able to uncheck it)
  • 'opt-out' (renderer will be checked by default for new posts, but author can uncheck it to disable it)
  • 'opt-in' (renderer will be unchecked by default for new posts, but author can check it to enable it)
  • 'lazy' (renderer will only apply to old posts that require it but will not be available for new posts)
  • 'never' (renderer will be invisible and inactive)

Example:

var $apply_when = 'opt-out';
Created by fplanque • Last edit by fplanque on 2013-03-06 02:33 • •

3 comments

Comment from: J. K. Hoffman

J. K. Hoffman

What would be really nice is some kind of API doc so we could write plugins for b2e. For instance, I wrote a moon phase plugin for WordPress and I’d like to adapt it to b2e for my wife, but I can’t for lack of info about the configuration and data structre. Good documentation would be great for this.

2004-08-19 @ 00:40

Comment from: isaac

Isaac

The Tech Documentation is about the closest thing you’ll find so far.

If you posted a fake email address, contact me via a comment or something and I’ll work with you to port over the moon phase thing if it can be done.

2004-08-19 @ 05:07

Comment from: Brian Feinzimer

Brian Feinzimer

It’s weird because out of no where I was getting PHP errors about line 47 which contianed the string

$this->index_Plugins[’b2evSmil’]->display();

and I had never gotten the error before…I’m guessing one of my smiley/toolbar thingy files got corrupted so I couldent use the item, I just removed the line and now it works.

I’m using 0.9.0.10

2005-07-19 @ 23:18

On this page

  • How to enable/disable a plugin
  • Plugin parameters
  • Toolbar plugins
  • priority
  • Renderer plugins
  • priority
  • apply-when

Search the Manual

Content Hierarchy

  • b2evolution CMS User Manual
  • User's Guide
  • Installation / Upgrade
  • Front-office Reference
  • Back-office Reference
  • Developer Reference
    • Website Skins/Themes
    • Email Skins/Themes
    • b2evolution Files
    • Website Integration
    • Plugins
      • Introduction to Plugins
      • Renderer Plugins
      • Plugin development
        • Localizing Plugins
        • Plugin API for item settings
        • Coding Standard Guidelines
        • How to turn plugins on/off
        • How to write a new plugin
        • Creating A Plugin
        • Plugin / Apply Rendering
        • Plugin Documentation
        • Plugins Repository
        • Creating an Antispam Plugin
        • List of Plugin Hooks
      • Plugin / Apply Rendering
      • Widget Plugins
    • Debugging
    • Technical Reference
    • Hacks
    • Credits
    • Development
    • How to... (Customize)
    • Scheduled Tasks Reference
  • Operations Reference
  • Advanced Topics
  • Glossary
  • Archives
CMS + forums

This online manual is powered by b2evolution CMS – A complete engine for your website.

About b2evolution

  • What is it?
  • Features
  • Getting Started
  • Screenshots
  • Online demo
  • Testimonials
  • Design philosophy
  • Free & open source
  • Terms of service

Downloads

  • Latest releases
  • Skins
  • Plugins
  • Language packs

About us

  • About us
  • Contact

Webhosting Guide

  • Web hosting blog
  • Best web hosting
  • Cheap web hosting
  • Green web hosting
  • Hosting with SSH
  • VPS hosting
  • Dedicated servers
  • Reseller hosting
  • Int'l: UK / France

Docs & Support

  • Online manual
  • Forums
  • Hire a pro !

Other

  • Adsense
  • Press room
  • Privacy policy

Stay in touch

  • GitHub
  • Twitter
  • Facebook
  • LinkedIn
  • News blog
  • RSS feed
  • Atom feed

Founded & Maintained by François Planque