plugin_name = $plugin_name; $this->plugin_path = $plugin_path; // handler // $this->initialize_event_handler(); } function get_link_icon($main_link, $action) { $link_url = add_url_params($main_link, array('ad' => $action)); return $link_url; } function loading_lang() { global $lang; //include(get_language_filepath('plugin.lang.php', $this->plugin_path)); load_language('plugin.lang', $this->plugin_path); } /* function remove_code($tlp_handle, $str_begin, $str_end) { global $template; $template->loadfile($tlp_handle); $p_beg = strpos($template->uncompiled_code[$tlp_handle], $str_begin); $p_end = strpos($template->uncompiled_code[$tlp_handle], $str_end) + strlen($str_end); $s = substr($template->uncompiled_code[$tlp_handle], $p_beg, $p_end - $p_beg); $template->uncompiled_code[$tlp_handle] = substr_replace($template->uncompiled_code[$tlp_handle], '', $p_beg, $p_end - $p_beg); return $s; } function add_before_code($tlp_handle, $insert_before, $code) { global $template; $template->loadfile($tlp_handle); $template->uncompiled_code[$tlp_handle] = str_replace($insert_before, $code.$insert_before, $template->uncompiled_code[$tlp_handle]); } function add_after_code($tlp_handle, $insert_after, $code) { global $template; $template->loadfile($tlp_handle); $template->uncompiled_code[$tlp_handle] = str_replace($insert_after, $insert_after.$code, $template->uncompiled_code[$tlp_handle]); }*/ function var_template() { global $user; if ($user['template'] == 'flop_pure_design') { $r = 'var_fpd.inc.php'; } else { $r = 'var.inc.php'; } return $r; } function link_charte_user($etat) { global $user, $lang; include($this->var_template()); if ($etat == 'not_defined') { /*$s = $this->remove_code('menubar',$begin_ident ,$end_ident); $this->add_before_code('menubar','',$s); $this->add_after_code('menubar','