7392274e2250780a133c5d11c2d8443a7b25595b

Author: Mark Story

Date: 2009-11-02 09:48:42 -0500

Moving escaping to view file, as escaping all tables breaks the timer bars.

diff --git a/views/elements/sql_log_panel.ctp b/views/elements/sql_log_panel.ctp index 0863c5f..b2c0cd8 100644 --- a/views/elements/sql_log_panel.ctp +++ b/views/elements/sql_log_panel.ctp @@ -25,7 +25,7 @@ <h4><?php echo $dbName ?></h4> <?php $headers = array('Nr', 'Query', 'Error', 'Affected', 'Num. rows', 'Took (ms)'); - echo $toolbar->table($queryLog['queries'], $headers, array('title' => 'SQL Log ' . $dbName)); + echo $toolbar->table(h($queryLog['queries']), $headers, array('title' => 'SQL Log ' . $dbName)); if (!empty($queryLog['explains'])): $name = sprintf(__d('debug_kit', 'toggle (%s) query explains for %s', true), count($queryLog['explains']), $dbName); @@ -35,7 +35,7 @@ foreach ($queryLog['explains'] as $explain): echo $toolbar->message(__d('debug_kit', 'Query:', true), $explain['query']); $headers = array_shift($explain['explain']); - echo $toolbar->table($explain['explain'], $headers); + echo $toolbar->table(h($explain['explain']), $headers); endforeach; echo '</div>'; else: diff --git a/views/helpers/html_toolbar.php b/views/helpers/html_toolbar.php index c6ab420..0e52082 100644 --- a/views/helpers/html_toolbar.php +++ b/views/helpers/html_toolbar.php @@ -124,7 +124,7 @@ class HtmlToolbarHelper extends ToolbarHelper { if (!empty($headers)) { $out .= $this->Html->tableHeaders($headers); } - $out .= $this->Html->tableCells(h($rows), array('class' => 'odd'), array('class' => 'even'), false, false); + $out .= $this->Html->tableCells($rows, array('class' => 'odd'), array('class' => 'even'), false, false); $out .= '</table>'; return $out; }