source: branches/2.0/plugins/event_tracer/tracer_admin.php @ 3192

Last change on this file since 3192 was 2771, checked in by rvelices, 16 years ago
  • event tracer improvement: option to show all registered event handlers for every page ...
  • Property svn:eol-style set to LF
  • Property svn:keywords set to Author Date Id Revision
File size: 1.3 KB
Line 
1<?php
2if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
3
4$me = get_plugin_data($plugin_id);
5
6global $template;
7$template->set_filenames( array('plugin_admin_content' => dirname(__FILE__).'/tracer_admin.tpl') );
8
9if ( isset($_POST['eventTracer_filters']) )
10{
11  $v = $_POST['eventTracer_filters'];
12  $v = str_replace( "\r\n", "\n", $v );
13  $v = str_replace( "\n\n", "\n", $v );
14  $v = stripslashes($v);
15  if (!empty($v))
16    $me->my_config['filters'] = explode("\n", $v);
17  else
18    $me->my_config['filters'] = array();
19  $me->my_config['show_args'] = isset($_POST['eventTracer_show_args']);
20  $me->my_config['show_registered'] = isset($_POST['eventTracer_show_registered']);
21  $me->save_config();
22  global $page;
23  array_push($page['infos'], 'event tracer options saved');
24}
25$template->assign('EVENT_TRACER_FILTERS', implode("\n", $me->my_config['filters'] ) );
26$template->assign('EVENT_TRACER_SHOW_ARGS', $me->my_config['show_args'] ? 'checked="checked"' : '' );
27$template->assign('U_LIST_EVENTS', get_admin_plugin_menu_link(dirname(__FILE__).'/event_list.php'));
28$template->assign('EVENT_TRACER_SHOW_REGISTERED', $me->my_config['show_registered'] ? 'checked="checked"' : '' );
29
30//$template->assign_var('EVENT_TRACER_F_ACTION', $my_url);
31
32$template->assign_var_from_handle( 'ADMIN_CONTENT', 'plugin_admin_content');
33?>
Note: See TracBrowser for help on using the repository browser.