diff options
-rw-r--r-- | html.class | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -81,7 +81,10 @@ function it_html($config = array()) # Create global functions for methods that are statically callable (have same arguments as global stubs) foreach (explode(",", $this->_staticallycallable) as $func) - $code[$func] = "function $func() { \$args = func_get_args(); return call_user_func_array(array(&\$GLOBALS['$this->_name'], '$func'), \$args); }"; + { + if ($func && !function_exists($func)) + $code[$func] = "function $func() { \$args = func_get_args(); return call_user_func_array(array(&\$GLOBALS['$this->_name'], '$func'), \$args); }"; + } eval(join("", (array)$code)); |