10 define(
"TITLE_core_debug", _(
"Debug Plugins"));
20 $this->Name =
"debug";
21 $this->Title = TITLE_core_debug;
22 $this->MenuList =
"Help::Debug::Debug Plugins";
24 parent::__construct();
33 if ($this->
State != PLUGIN_STATE_READY)
37 if ($this->OutputToStdout && $this->OutputType==
"Text") {
42 if ($this->OutputType==
'HTML')
44 $output = $this->htmlContent();
46 if (!$this->OutputToStdout)
48 $this->vars[
'content'] = $output;
58 protected function htmlContent()
66 $text = _(
"Plugin Summary");
67 $V .=
"<H2>$text</H2>";
68 foreach ($Plugins as $key => $val)
70 $V .=
"$key : $val->Name (state=$val->State)<br>\n";
72 $text = _(
"Plugin State Details");
73 $V .=
"<H2>$text</H2>";
75 foreach ($Plugins as $plugin)
77 $V .= strval($plugin) .
"\n";
86 $NewPlugin->Initialize();
This is the Plugin class. All plugins should:
__construct()
base constructor. Most plugins will just use this
Output()
display the loaded menu and plugins.
#define PLUGIN_DB_ADMIN
Plugin requires admin level permission on DB.