[1580] | 1 | <?php |
---|
| 2 | if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!'); |
---|
| 3 | |
---|
[1705] | 4 | $me = get_plugin_data($plugin_id); |
---|
| 5 | |
---|
[1580] | 6 | global $template; |
---|
| 7 | $template->set_filenames( array('plugin_admin_content' => dirname(__FILE__).'/tracer_admin.tpl') ); |
---|
| 8 | |
---|
| 9 | if ( 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 ); |
---|
[1655] | 14 | $v = stripslashes($v); |
---|
| 15 | if (!empty($v)) |
---|
[1705] | 16 | $me->my_config['filters'] = explode("\n", $v); |
---|
[1655] | 17 | else |
---|
[1705] | 18 | $me->my_config['filters'] = array(); |
---|
| 19 | $me->my_config['show_args'] = isset($_POST['eventTracer_show_args']); |
---|
[2773] | 20 | $me->my_config['show_registered'] = isset($_POST['eventTracer_show_registered']); |
---|
[3611] | 21 | if (isset($_POST['eventTracer_show_included_files']) ) |
---|
| 22 | $me->my_config['show_included_files'] = true; |
---|
| 23 | else |
---|
| 24 | unset($me->my_config['show_included_files']); |
---|
[1705] | 25 | $me->save_config(); |
---|
[1580] | 26 | global $page; |
---|
| 27 | array_push($page['infos'], 'event tracer options saved'); |
---|
| 28 | } |
---|
[2254] | 29 | $template->assign('EVENT_TRACER_FILTERS', implode("\n", $me->my_config['filters'] ) ); |
---|
[3611] | 30 | $template->assign('EVENT_TRACER_SHOW_ARGS', @$me->my_config['show_args'] ? 'checked="checked"' : '' ); |
---|
[2254] | 31 | $template->assign('U_LIST_EVENTS', get_admin_plugin_menu_link(dirname(__FILE__).'/event_list.php')); |
---|
[3611] | 32 | $template->assign('EVENT_TRACER_SHOW_REGISTERED', @$me->my_config['show_registered'] ? 'checked="checked"' : '' ); |
---|
| 33 | $template->assign('EVENT_TRACER_SHOW_INCLUDED_FILES', @$me->my_config['show_included_files'] ? 'checked="checked"' : '' ); |
---|
[1793] | 34 | |
---|
[1705] | 35 | //$template->assign_var('EVENT_TRACER_F_ACTION', $my_url); |
---|
[1580] | 36 | |
---|
[1705] | 37 | $template->assign_var_from_handle( 'ADMIN_CONTENT', 'plugin_admin_content'); |
---|
[1793] | 38 | ?> |
---|