Admin Status menu, adding a plugin to

From e107 Wiki
Jump to: navigation, search

e107 Wiki: English | Русский | Deutsch | Français | Magyar | Português | Български | Česky | Nederlands | Ελληνικά | Italiano | Norske | Polska | Slovenščina | Español | Svenska | Translate: Wiki | Page

logo_wiki.png

Current Release 1.0.4 | e107.org | Download | Changelog | Forum | Plugins | Themes | RSS Feed of Latest Changes | Atom Feed of Latest Changes


How to write a plugin
Main page > I : First Aid > II : Development > III : Administration > IV : How To's > V : Plugin Writing > VI : Theming & Shortcodes


As of e107 0.7 a plugin can add it's own information to the Status menu displayed in the admin area.

There are two steps to this process.

First off is to register the use of these features with core when the plugin is installed by inserting the following line to your plugin.php:

Code: plugin.php snippet
$eplug_status = TRUE;

The next step is to create the file e_status.php your plugins root folder.

You can place any code in here you wish, depending on the information you want to display, noting that everything these files output must be in the $text variable in an appended form (ie. with '.=' not'='). Below is an example of the e_status.php taken from the cores Forum plugin:

Code: e_status from forum plugin
$forum_posts = $sql -> db_Count("forum_t");

$text .= "
<div style='padding-bottom: 2px;'>".E_16_FORUM." ".ADLAN_113.": ".$forum_posts."</div>";


The Chatbox plugin also contains an example of an e_status.php file.