debug toolbar WIP

This commit is contained in:
Qiang Xue
2013-06-27 21:50:38 -04:00
parent 16dcd9701f
commit 20666567e8
9 changed files with 116 additions and 61 deletions

View File

@@ -0,0 +1 @@
here we are

View File

@@ -19,21 +19,22 @@ echo Html::style("
margin: 0 10px;
");
?>
<div id="yii-debug-toolbar">
<div class="yii-debug-toolbar-block">
<?php echo Html::a('more details', array('index', 'tag' => $tag)); ?>
</div>
<div class="yii-debug-toolbar-block">
<div class="yii-debug-toolbar-block">
Peak memory: <?php echo sprintf('%.2fMB', $memory / 1048576); ?>
</div>
<div class="yii-debug-toolbar-block">
Time spent: <?php echo sprintf('%.3fs', $time); ?>
</div>
<div class="yii-debug-toolbar-block">
</div>
<div class="yii-debug-toolbar-block">
</div>
</div>
<div class="yii-debug-toolbar-block">
Peak memory: <?php echo sprintf('%.2fMB', $memory / 1048576); ?>
</div>
<div class="yii-debug-toolbar-block">
Time spent: <?php echo sprintf('%.3fs', $time); ?>
</div>
<div class="yii-debug-toolbar-block">
</div>
<div class="yii-debug-toolbar-block">
</div>

View File

@@ -0,0 +1,21 @@
<?php
/**
* @var \yii\base\View $this
* @var string $content
*/
use yii\helpers\Html;
?>
<!DOCTYPE html>
<html>
<?php $this->beginPage(); ?>
<head>
<title><?php echo Html::encode($this->title); ?></title>
<?php $this->head(); ?>
</head>
<body>
<?php $this->beginBody(); ?>
<?php echo $content; ?>
<?php $this->endBody(); ?>
</body>
<?php $this->endPage(); ?>
</html>