protected function loaderHooks($instance,$hook_name,$class='',$method_name='',$data=array())
    {
        $hooks = configItem('hooks');

        if(isset($hooks[$hook_name]) && $hooks[$hook_name]['active'])
        {
            $ns         = "\\application\\".$hooks[$hook_name]['namespace'];
            $hook_class = $hooks[$hook_name]['class'];
            $class_ns   = "$ns\\$hook_class";

            $hook_instance = new $class_ns();
            if($hook_name == 'pre_template')
            {
                $para = array($instance,$class,$method_name,$data);
            }
            else
            {
                $para = array($instance,$data);
            }
            call_user_func_array(array($hook_instance, $hooks[$hook_name]['method']), $para);
        }

    }