Source for file console.phtml
Documentation is available at console.phtml
- 1: <?php
- 3: /**
- 4: * Nette Framework - Dump console template.
- 5: *
- 11: *
- 14: */
- 21: {
- 22: return "$m[1]<a href='#' onclick='return !netteToggle(this)'>$m[2]($m[3]) " . ($m[3] < 7 ? '<abbr>▼</abbr> </a><code>' : '<abbr>►</abbr> </a><code class="collapsed">');
- 23: }
- 24: }
- 28: ?><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
- 29: <html lang="en">
- 30: <head>
- 31: <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
- 32: <meta name="robots" content="noindex,noarchive">
- 33: <meta name="generator" content="Nette Framework">
- 35: <title>Nette Debug Console</title>
- 37: <style type="text/css">
- 38: /* <![CDATA[ */
- 39: body {
- 40: margin: 0;
- 41: padding: 0;
- 42: font: 9pt/1.5 Verdana, sans-serif;
- 43: background: white;
- 44: color: #333;
- 45: }
- 47: h1 {
- 48: font-size: 13pt;
- 49: margin: 0;
- 50: padding: 2px 8px;
- 51: background: black;
- 52: color: white;
- 53: border-bottom: 1px solid black;
- 54: }
- 56: h2 {
- 57: font: 11pt/1.5 sans-serif;
- 58: margin: 0;
- 59: padding: 2px 8px;
- 60: background: #3484d2;
- 61: color: white;
- 62: }
- 64: a {
- 65: text-decoration: none;
- 66: color: #4197E3;
- 67: }
- 69: a abbr {
- 70: font-family: sans-serif;
- 71: color: #999;
- 72: }
- 74: p {
- 75: margin: .8em 0
- 76: }
- 78: pre, code, table {
- 79: font: 9pt/1.5 Consolas, monospace;
- 80: }
- 82: pre, table {
- 83: background: #fffbcc;
- 84: padding: .4em .7em;
- 85: border: 1px dotted silver;
- 86: }
- 88: table pre {
- 89: padding: 0;
- 90: margin: 0;
- 91: border: none;
- 92: }
- 94: pre.dump span {
- 95: color: #c16549;
- 96: }
- 98: pre.dump a {
- 99: color: #333;
- 100: }
- 102: table {
- 103: border-collapse: collapse;
- 104: width: 100%;
- 105: }
- 107: td, th {
- 108: vertical-align: top;
- 109: text-align: left;
- 110: border: 1px solid #eeeebb;
- 111: }
- 113: th {
- 114: width: 10;
- 115: padding: 2px 3px 2px 8px;
- 116: font-weight: bold;
- 117: }
- 119: td {
- 120: padding: 2px 8px 2px 3px;
- 121: }
- 123: .odd, .odd pre {
- 124: background: #faf5c3;
- 125: }
- 127: /* ]]> */
- 128: </style>
- 131: <script type="text/javascript">
- 132: /* <![CDATA[ */
- 133: document.write('<style> .collapsed { display: none; } <\/style>');
- 135: function netteToggle(link, panelId)
- 136: {
- 137: var arrow = link.getElementsByTagName('abbr')[0];
- 138: var panel = panelId ? document.getElementById(panelId) : link.nextSibling;
- 139: while (panel.nodeType !== 1) panel = panel.nextSibling;
- 140: var collapsed = panel.currentStyle ? panel.currentStyle.display == 'none' : getComputedStyle(panel, null).display == 'none';
- 142: arrow.innerHTML = String.fromCharCode(collapsed ? 0x25bc : 0x25ba);
- 143: panel.style.display = collapsed ? (panel.tagName.toLowerCase() === 'code' ? 'inline' : 'block') : 'none';
- 145: return true;
- 146: }
- 147: /* ]]> */
- 148: </script>
- 149: </head>
- 153: <body>
- 154: <h1>Nette Debug Console</h1>
- 155: </body>
- 156: </html>
- 165: <table>
- 170: <td><?php echo preg_replace_callback('#(<pre class="dump">|\s+)?(.*)\((\d+)\) <code>#', '_netteDumpCb2', $dump) ?></td>
- 171: </tr>
- 173: </table>
- 177: <script type="text/javascript">
- 178: /* <![CDATA[ */
- 179: if (typeof _netteConsole === 'undefined') {
- 180: _netteConsole = window.open('','_netteConsole','width=700,height=700,resizable,scrollbars=yes');
- 181: _netteConsole.document.write(<?php echo json_encode(preg_replace('#[ \t\r\n]+#', ' ', $document)) ?>);
- 182: _netteConsole.document.close();
- 183: _netteConsole.document.onkeyup = function(e) {
- 184: e = e || _netteConsole.event;
- 185: if (e.keyCode == 27) _netteConsole.close();
- 186: }
- 187: _netteConsole.document.body.focus();
- 188: }
- 189: _netteConsole.document.body.innerHTML = _netteConsole.document.body.innerHTML + <?php echo json_encode($body) ?>;
- 190: /* ]]> */
- 191: </script>