From 09dfe32eb6b538225686fd6ed0220240010bc574 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Mon, 1 Aug 2011 01:22:36 -0400 Subject: initial commit. Partway through a rewrite. I have some old files I didn't want to entirely delete. --- src/lib/MessageHandler.class.php | 55 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 src/lib/MessageHandler.class.php (limited to 'src/lib/MessageHandler.class.php') diff --git a/src/lib/MessageHandler.class.php b/src/lib/MessageHandler.class.php new file mode 100644 index 0000000..2dce491 --- /dev/null +++ b/src/lib/MessageHandler.class.php @@ -0,0 +1,55 @@ + $type) { + $value = $m->getPluginConf($plugin, $param); + if ($value!==false) { + switch ($type) { + case 'text': + case 'password': + $value = "$value"; + break; + case 'int': + $value = (int)$value; + break; + } + configSet($param, $value); + } + } + return $obj; + } + public function main() { + global $BASE; + + $private_senders = array(); + $broadcast_senders = array(); + + $plugin_list = $m->getSysConf('plugins'); + $plugins = explode(',', $plugin_list); + foreach ($plugins as $plugin) { + require_once("$plugin.class.php"); + if (is_subclass_of($plugin, 'SenderPrivate')) { + $private_senders[] = $this->loadPlugin($plugin); + } + if (is_subclass_of($plugin, 'SenderBroadcast')) { + $broadcast_senders[] = $this->loadPlugin($plugin); + } + } + //foreach ($private_senders) + } +} \ No newline at end of file -- cgit v1.2.3-2-g168b