Registry::get('view')->assign('data', $data['logging']); Registry::get('view')->assign('debugger_hash', $_REQUEST['debugger_hash']); Registry::get('view')->display('views/debugger/components/logging_tab.tpl'); } exit; } elseif ($mode == 'templates') { if (!empty($data['templates'])) { $data['templates']['tpls'] = Debugger::parseTplsList($data['templates']['tpls'], 0); Registry::get('view')->assign('data', $data['templates']); Registry::get('view')->assign('debugger_hash', $_REQUEST['debugger_hash']); Registry::get('view')->display('views/debugger/components/templates_tab.tpl'); } exit; } elseif ($mode == 'blocks') { if (!empty($data['blocks'])) { $blocks_rendered = array_filter($data['blocks'], function ($block) { return !$block['render_performance']['found_at_cache']; }); $blocks_from_cache = array_filter($data['blocks'], function ($block) { return $block['render_performance']['found_at_cache']; }); Registry::get('view')->assign('blocks_rendered', $blocks_rendered); Registry::get('view')->assign('blocks_from_cache', $blocks_from_cache); Registry::get('view')->assign('debugger_hash', $_REQUEST['debugger_hash']); Registry::get('view')->display('views/debugger/components/blocks_tab.tpl'); } exit; } elseif ($mode == 'quit') { Debugger::quit(); return array(CONTROLLER_STATUS_REDIRECT, fn_query_remove($_REQUEST['redirect_url'], Registry::get('config.debugger_token'))); }