From 85f30c0292ecebf3668e024314e6011d0b4d7934 Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 7 Mar 2015 16:31:13 -0800 Subject: [PATCH] PHP Notice removal --- e107_handlers/e107_class.php | 2 +- e107_handlers/e_parse_class.php | 9 ++++++--- e107_handlers/plugin_class.php | 12 +++++++++++- 3 files changed, 18 insertions(+), 5 deletions(-) diff --git a/e107_handlers/e107_class.php b/e107_handlers/e107_class.php index 5899ed6d2..e6987075c 100644 --- a/e107_handlers/e107_class.php +++ b/e107_handlers/e107_class.php @@ -1870,7 +1870,7 @@ class e107 * Safe way to call user methods. * @param string|object $class_name * @param string $method_name - * @return boolean FALSE + * @return array|boolean FALSE */ public static function callMethod($class_name, $method_name, $param='') { diff --git a/e107_handlers/e_parse_class.php b/e107_handlers/e_parse_class.php index 97567236a..0f36a93e6 100644 --- a/e107_handlers/e_parse_class.php +++ b/e107_handlers/e_parse_class.php @@ -3165,7 +3165,7 @@ class e_parser */ public function cleanHtml($html='', $checkPref = true) { - if(empty($html)){ return; } + if(empty($html)){ return ''; } // $html = mb_convert_encoding($html, 'UTF-8'); @@ -3269,9 +3269,12 @@ class e_parser } // required - removing attributes in a loop breaks the loop - foreach ($removeAttributes as $name) + if(!empty($removeAttributes)) { - $node->removeAttribute($name); + foreach ($removeAttributes as $name) + { + $node->removeAttribute($name); + } } diff --git a/e107_handlers/plugin_class.php b/e107_handlers/plugin_class.php index 1f7dfdcff..56fd5493a 100644 --- a/e107_handlers/plugin_class.php +++ b/e107_handlers/plugin_class.php @@ -2986,9 +2986,19 @@ class e107plugin // Called to parse the (deprecated) plugin.php file function parse_plugin_php($plugName) { - $mes = e107::getMessage(); $tp = e107::getParser(); + $eplug_conffile = null; + $eplug_table_names = null; + $eplug_prefs = null; + $eplug_module = null; + $eplug_userclass = null; + $eplug_status = null; + $eplug_latest = null; + $eplug_icon = null; + $eplug_icon_small = null; + + if (include(e_PLUGIN.$plugName.'/plugin.php')) { //$mes->add("Loading ".e_PLUGIN.$plugName.'/plugin.php', E_MESSAGE_DEBUG);