diff options
| author | Patrick Seeger <pseeger@ccwn.org> | 2012-04-13 23:11:05 +0200 |
|---|---|---|
| committer | Patrick Seeger <pseeger@ccwn.org> | 2012-04-13 23:11:05 +0200 |
| commit | 341cc4dd9c53ffbfb863e026dd58549c1082c7a7 (patch) | |
| tree | 1bbbed20313bafb9b063b6b4d894fe580d8b000f /framework/views/sv | |
Diffstat (limited to 'framework/views/sv')
| -rw-r--r-- | framework/views/sv/error.php | 37 | ||||
| -rw-r--r-- | framework/views/sv/error400.php | 33 | ||||
| -rw-r--r-- | framework/views/sv/error403.php | 33 | ||||
| -rw-r--r-- | framework/views/sv/error404.php | 33 | ||||
| -rw-r--r-- | framework/views/sv/error500.php | 35 | ||||
| -rw-r--r-- | framework/views/sv/error503.php | 31 | ||||
| -rw-r--r-- | framework/views/sv/exception.php | 242 | ||||
| -rw-r--r-- | framework/views/sv/log-firebug.php | 23 | ||||
| -rw-r--r-- | framework/views/sv/log.php | 40 | ||||
| -rw-r--r-- | framework/views/sv/profile-callstack-firebug.php | 19 | ||||
| -rw-r--r-- | framework/views/sv/profile-callstack.php | 30 | ||||
| -rw-r--r-- | framework/views/sv/profile-summary-firebug.php | 22 | ||||
| -rw-r--r-- | framework/views/sv/profile-summary.php | 41 |
13 files changed, 619 insertions, 0 deletions
diff --git a/framework/views/sv/error.php b/framework/views/sv/error.php new file mode 100644 index 0000000..df6ee14 --- /dev/null +++ b/framework/views/sv/error.php @@ -0,0 +1,37 @@ +<!DOCTYPE html PUBLIC + "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> +<title>Fel <?php echo $data['code']; ?></title> + +<style type="text/css"> +/*<![CDATA[*/ +body {font-family:"Verdana";font-weight:normal;color:black;background-color:white;} +h1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red } +h2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon } +h3 {font-family:"Verdana";font-weight:bold;font-size:11pt} +p {font-family:"Verdana";font-weight:normal;color:black;font-size:9pt;margin-top: -5px} +.version {color: gray;font-size:8pt;border-top:1px solid #aaaaaa;} +/*]]>*/ +</style> +</head> + +<body> +<h1>Fel <?php echo $data['code']; ?></h1> +<h2><?php echo nl2br(CHtml::encode($data['message'])); ?></h2> +<p> +Ovanstående fel uppstod när servern behandlade Er förfrågan. +</p> +<p> +Vid misstanke om serverfel, kontakta <?php echo $data['admin']; ?>. +</p> +<p> +Tack. +</p> +<div class="version"> +<?php echo date('Y-m-d H:i:s',$data['time']) .' '. $data['version']; ?> +</div> +</body> +</html>
\ No newline at end of file diff --git a/framework/views/sv/error400.php b/framework/views/sv/error400.php new file mode 100644 index 0000000..b30045e --- /dev/null +++ b/framework/views/sv/error400.php @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC + "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> +<title>Felaktig förfrågan</title> +<style type="text/css"> +/*<![CDATA[*/ +body {font-family:"Verdana";font-weight:normal;color:black;background-color:white;} +h1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red } +h2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon } +h3 {font-family:"Verdana";font-weight:bold;font-size:11pt} +p {font-family:"Verdana";font-weight:normal;color:black;font-size:9pt;margin-top: -5px} +.version {color: gray;font-size:8pt;border-top:1px solid #aaaaaa;} +/*]]>*/ +</style> +</head> +<body> +<h1>Felaktig förfrågan</h1> +<h2><?php echo nl2br(CHtml::encode($data['message'])); ?></h2> +<p> +Servern förstod inte denna förfrågan på grund av felaktig syntax. +Vänligen repetera inte denna förfrågan omodifierad. +</p> +<p> +Vid misstanke om serverfel, kontakta <?php echo $data['admin']; ?>. +</p> +<div class="version"> +<?php echo date('Y-m-d H:i:s',$data['time']) .' '. $data['version']; ?> +</div> +</body> +</html>
\ No newline at end of file diff --git a/framework/views/sv/error403.php b/framework/views/sv/error403.php new file mode 100644 index 0000000..76e5a63 --- /dev/null +++ b/framework/views/sv/error403.php @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC + "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> +<title>Ej auktoriserad</title> +<style type="text/css"> +/*<![CDATA[*/ +body {font-family:"Verdana";font-weight:normal;color:black;background-color:white;} +h1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red } +h2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon } +h3 {font-family:"Verdana";font-weight:bold;font-size:11pt} +p {font-family:"Verdana";font-weight:normal;color:black;font-size:9pt;margin-top: -5px} +.version {color: gray;font-size:8pt;border-top:1px solid #aaaaaa;} +/*]]>*/ +</style> +</head> +<body> +<h1>Ej auktoriserad</h1> +<h2><?php echo nl2br(CHtml::encode($data['message'])); ?></h2> +<p> +Otillräckliga rättigheter för åtkomst till denna sida. +</p> +<p> +Vid misstanke om serverfel, kontakta <?php echo $data['admin']; ?>. + +</p> +<div class="version"> +<?php echo date('Y-m-d H:i:s',$data['time']) .' '. $data['version']; ?> +</div> +</body> +</html>
\ No newline at end of file diff --git a/framework/views/sv/error404.php b/framework/views/sv/error404.php new file mode 100644 index 0000000..779f713 --- /dev/null +++ b/framework/views/sv/error404.php @@ -0,0 +1,33 @@ +<!DOCTYPE html PUBLIC + "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> +<title>Sidan hittades inte</title> +<style type="text/css"> +/*<![CDATA[*/ +body {font-family:"Verdana";font-weight:normal;color:black;background-color:white;} +h1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red } +h2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon } +h3 {font-family:"Verdana";font-weight:bold;font-size:11pt} +p {font-family:"Verdana";font-weight:normal;color:black;font-size:9pt;margin-top: -5px} +.version {color: gray;font-size:8pt;border-top:1px solid #aaaaaa;} +/*]]>*/ +</style> +</head> +<body> +<h1>Sidan hittades inte</h1> +<h2><?php echo nl2br(CHtml::encode($data['message'])); ?></h2> +<p> +Den begärda URL:en hittades inte på denna server. +Om URL:en matades in manuellt, kontrollera stavningen och försök igen. +</p> +<p> +Vid misstanke om serverfel, kontakta <?php echo $data['admin']; ?>. +</p> +<div class="version"> +<?php echo date('Y-m-d H:i:s',$data['time']) .' '. $data['version']; ?> +</div> +</body> +</html>
\ No newline at end of file diff --git a/framework/views/sv/error500.php b/framework/views/sv/error500.php new file mode 100644 index 0000000..0f78b57 --- /dev/null +++ b/framework/views/sv/error500.php @@ -0,0 +1,35 @@ +<!DOCTYPE html PUBLIC + "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> +<title>Internt serverfel</title> + +<style type="text/css"> +/*<![CDATA[*/ +body {font-family:"Verdana";font-weight:normal;color:black;background-color:white;} +h1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red } +h2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon } +h3 {font-family:"Verdana";font-weight:bold;font-size:11pt} +p {font-family:"Verdana";font-weight:normal;color:black;font-size:9pt;margin-top: -5px} +.version {color: gray;font-size:8pt;border-top:1px solid #aaaaaa;} +/*]]>*/ +</style> +</head> + +<body> +<h1>Internt serverfel</h1> +<h2><?php echo nl2br(CHtml::encode($data['message'])); ?></h2> +<p> +Ett internt fel uppstod vid behandlingen av Er begäran. +Vänligen kontakta <?php echo $data['admin']; ?> för att rapportera detta problem. +</p> +<p> +Tack. +</p> +<div class="version"> +<?php echo date('Y-m-d H:i:s',$data['time']) .' '. $data['version']; ?> +</div> +</body> +</html>
\ No newline at end of file diff --git a/framework/views/sv/error503.php b/framework/views/sv/error503.php new file mode 100644 index 0000000..db8902f --- /dev/null +++ b/framework/views/sv/error503.php @@ -0,0 +1,31 @@ +<!DOCTYPE html PUBLIC + "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> +<title>Tjänsten ej tillgänglig</title> +<style type="text/css"> +/*<![CDATA[*/ +body {font-family:"Verdana";font-weight:normal;color:black;background-color:white;} +h1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red } +h2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon } +h3 {font-family:"Verdana";font-weight:bold;font-size:11pt} +p {font-family:"Verdana";font-weight:normal;color:black;font-size:9pt;margin-top: -5px} +.version {color: gray;font-size:8pt;border-top:1px solid #aaaaaa;} +/*]]>*/ +</style> +</head> +<body> +<h1>Tjänsten ej tillgänglig</h1> +<p> +Vårt system är för närvarande stängt pga underhåll. Vänligen kom tillbaka senare. +</p> +<p> +Tack. +</p> +<div class="version"> +<?php echo date('Y-m-d H:i:s',$data['time']) .' '. $data['version']; ?> +</div> +</body> +</html>
\ No newline at end of file diff --git a/framework/views/sv/exception.php b/framework/views/sv/exception.php new file mode 100644 index 0000000..21d4f4c --- /dev/null +++ b/framework/views/sv/exception.php @@ -0,0 +1,242 @@ +<!DOCTYPE html PUBLIC + "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> +<title><?php echo CHtml::encode($data['type'])?></title> + +<style type="text/css"> +/*<![CDATA[*/ +html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,font,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td{border:0;outline:0;font-size:100%;vertical-align:baseline;background:transparent;margin:0;padding:0;} +body{line-height:1;} +ol,ul{list-style:none;} +blockquote,q{quotes:none;} +blockquote:before,blockquote:after,q:before,q:after{content:none;} +:focus{outline:0;} +ins{text-decoration:none;} +del{text-decoration:line-through;} +table{border-collapse:collapse;border-spacing:0;} + +body { + font: normal 9pt "Verdana"; + color: #000; + background: #fff; +} + +h1 { + font: normal 18pt "Verdana"; + color: #f00; + margin-bottom: .5em; +} + +h2 { + font: normal 14pt "Verdana"; + color: #800000; + margin-bottom: .5em; +} + +h3 { + font: bold 11pt "Verdana"; +} + +pre { + font: normal 11pt Menlo, Consolas, "Lucida Console", Monospace; +} + +pre span.error { + display: block; + background: #fce3e3; +} + +pre span.ln { + color: #999; + padding-right: 0.5em; + border-right: 1px solid #ccc; +} + +pre span.error-ln { + font-weight: bold; +} + +.container { + margin: 1em 4em; +} + +.version { + color: gray; + font-size: 8pt; + border-top: 1px solid #aaa; + padding-top: 1em; + margin-bottom: 1em; +} + +.message { + color: #000; + padding: 1em; + font-size: 11pt; + background: #f3f3f3; + -webkit-border-radius: 10px; + -moz-border-radius: 10px; + border-radius: 10px; + margin-bottom: 1em; + line-height: 160%; +} + +.source { + margin-bottom: 1em; +} + +.code pre { + background-color: #ffe; + margin: 0.5em 0; + padding: 0.5em; + line-height: 125%; + border: 1px solid #eee; +} + +.source .file { + margin-bottom: 1em; + font-weight: bold; +} + +.traces { + margin: 2em 0; +} + +.trace { + margin: 0.5em 0; + padding: 0.5em; +} + +.trace.app { + border: 1px dashed #c00; +} + +.trace .number { + text-align: right; + width: 2em; + padding: 0.5em; +} + +.trace .content { + padding: 0.5em; +} + +.trace .plus, +.trace .minus { + display:inline; + vertical-align:middle; + text-align:center; + border:1px solid #000; + color:#000; + font-size:10px; + line-height:10px; + margin:0; + padding:0 1px; + width:10px; + height:10px; +} + +.trace.collapsed .minus, +.trace.expanded .plus, +.trace.collapsed pre { + display: none; +} + +.trace-file { + cursor: pointer; + padding: 0.2em; +} + +.trace-file:hover { + background: #f0ffff; +} +/*]]>*/ +</style> +</head> + +<body> +<div class="container"> + <h1><?php echo $data['type']?></h1> + + <p class="message"> + <?php echo nl2br(CHtml::encode($data['message']))?> + </p> + + <div class="source"> + <p class="file"><?php echo CHtml::encode($data['file'])."({$data['line']})"?></p> + <?php echo $this->renderSourceCode($data['file'],$data['line'],$this->maxSourceLines); ?> + </div> + + <div class="traces"> + <h2>Stackspårning</h2> + <?php $count=0; ?> + <table style="width:100%;"> + <?php foreach($data['traces'] as $n => $trace): ?> + <?php + if($this->isCoreCode($trace)) + $cssClass='core collapsed'; + else if(++$count>3) + $cssClass='app collapsed'; + else + $cssClass='app expanded'; + $hasCode=$trace['file']!=='unknown' && is_file($trace['file']); + ?> + <tr class="trace <?php echo $cssClass; ?>"> + <td class="number"> + #<?php echo $n; ?> + </td> + <td class="content"> + <div class="trace-file"> + <?php if($hasCode): ?> + <div class="plus">+</div> + <div class="minus">–</div> + <?php endif; ?> + <?php + echo ' '; + echo CHtml::encode($trace['file'])."(".$trace['line'].")"; + echo ': '; + if(!empty($trace['class'])) + echo "<strong>{$trace['class']}</strong>{$trace['type']}"; + echo "<strong>{$trace['function']}</strong>("; + if(!empty($trace['args'])) + echo CHtml::encode($this->argumentsToString($trace['args'])); + echo ')'; + ?> + </div> + + <?php if($hasCode) echo $this->renderSourceCode($trace['file'],$trace['line'],$this->maxTraceSourceLines); ?> + </td> + </tr> + <?php endforeach; ?> + </table> + </div> + + <div class="version"> + <?php echo date('Y-m-d H:i:s',$data['time']) .' '. $data['version']; ?> + </div> +</div> + +<script type="text/javascript"> +/*<![CDATA[*/ +var traceReg = new RegExp("(^|\\s)trace-file(\\s|$)"); +var collapsedReg = new RegExp("(^|\\s)collapsed(\\s|$)"); + +var e = document.getElementsByTagName("div"); +for(var j=0,len=e.length;j<len;j++){ + if(traceReg.test(e[j].className)){ + e[j].onclick = function(){ + var trace = this.parentNode.parentNode; + if(collapsedReg.test(trace.className)) + trace.className = trace.className.replace("collapsed", "expanded"); + else + trace.className = trace.className.replace("expanded", "collapsed"); + } + } +} +/*]]>*/ +</script> + +</body> +</html> diff --git a/framework/views/sv/log-firebug.php b/framework/views/sv/log-firebug.php new file mode 100644 index 0000000..50ab07a --- /dev/null +++ b/framework/views/sv/log-firebug.php @@ -0,0 +1,23 @@ +<script type="text/javascript"> +/*<![CDATA[*/ +if(typeof(console)=='object') +{ + console.group("Applikationslogg"); +<?php +foreach($data as $index=>$log) +{ + $time=date('H:i:s.',$log[3]).sprintf('%03d',(int)(($log[3]-(int)$log[3])*1000)); + if($log[1]===CLogger::LEVEL_WARNING) + $func='warn'; + else if($log[1]===CLogger::LEVEL_ERROR) + $func='error'; + else + $func='log'; + $content=CJavaScript::quote("[$time][$log[1]][$log[2]] $log[0]"); + echo "\tconsole.{$func}(\"{$content}\");\n"; +} +?> + console.groupEnd(); +} +/*]]>*/ +</script>
\ No newline at end of file diff --git a/framework/views/sv/log.php b/framework/views/sv/log.php new file mode 100644 index 0000000..f158a37 --- /dev/null +++ b/framework/views/sv/log.php @@ -0,0 +1,40 @@ +<!-- start log messages --> +<table class="yiiLog" width="100%" cellpadding="2" style="border-spacing:1px;font:11px Verdana, Arial, Helvetica, sans-serif;background:#EEEEEE;color:#666666;"> + <tr> + <th style="background:black;color:white;" colspan="5"> + Applikationslogg + </th> + </tr> + <tr style="background-color: #ccc;"> + <th style="width:120px">Tidstämpel</th> + <th>Nivå</th> + <th>Kategori</th> + <th>Meddelande</th> + </tr> +<?php +$colors=array( + CLogger::LEVEL_PROFILE=>'#DFFFE0', + CLogger::LEVEL_INFO=>'#FFFFDF', + CLogger::LEVEL_WARNING=>'#FFDFE5', + CLogger::LEVEL_ERROR=>'#FFC0CB', +); +foreach($data as $index=>$log) +{ + $color=($index%2)?'#F5F5F5':'#FFFFFF'; + if(isset($colors[$log[1]])) + $color=$colors[$log[1]]; + $message='<pre>'.CHtml::encode(wordwrap($log[0])).'</pre>'; + $time=date('H:i:s.',$log[3]).sprintf('%06d',(int)(($log[3]-(int)$log[3])*1000000)); + + echo <<<EOD + <tr style="background:{$color}"> + <td align="center">{$time}</td> + <td>{$log[1]}</td> + <td>{$log[2]}</td> + <td>{$message}</td> + </tr> +EOD; +} +?> +</table> +<!-- end of log messages -->
\ No newline at end of file diff --git a/framework/views/sv/profile-callstack-firebug.php b/framework/views/sv/profile-callstack-firebug.php new file mode 100644 index 0000000..a35e5cb --- /dev/null +++ b/framework/views/sv/profile-callstack-firebug.php @@ -0,0 +1,19 @@ +<script type="text/javascript"> +/*<![CDATA[*/ +if(typeof(console)=='object') +{ + console.group("Profileringsrapport - Anropsstack"); +<?php +foreach($data as $index=>$entry) +{ + list($proc,$time,$level)=$entry; + $proc=CJavaScript::quote($proc); + $time=sprintf('%0.5f',$time); + $spaces=str_repeat(' ',$level*8); + echo "\tconsole.log(\"[$time]{$spaces}{$proc}\");\n"; +} +?> + console.groupEnd(); +} +/*]]>*/ +</script>
\ No newline at end of file diff --git a/framework/views/sv/profile-callstack.php b/framework/views/sv/profile-callstack.php new file mode 100644 index 0000000..837cb6e --- /dev/null +++ b/framework/views/sv/profile-callstack.php @@ -0,0 +1,30 @@ +<!-- start profiling callstack --> +<table class="yiiLog" width="100%" cellpadding="2" style="border-spacing:1px;font:11px Verdana, Arial, Helvetica, sans-serif;background:#EEEEEE;color:#666666;"> + <tr> + <th style="background:black;color:white;" colspan="2"> + Profileringsrapport - Anropsstack + </th> + </tr> + <tr style="background-color: #ccc;"> + <th>Procedur</th> + <th>Tid (s)</th> + </tr> +<?php +foreach($data as $index=>$entry) +{ + $color=($index%2)?'#F5F5F5':'#FFFFFF'; + list($proc,$time,$level)=$entry; + $proc=CHtml::encode($proc); + $time=sprintf('%0.5f',$time); + $spaces=str_repeat(' ',$level*8); + + echo <<<EOD + <tr style="background:{$color}"> + <td>{$spaces}{$proc}</td> + <td align="center">{$time}</td> + </tr> +EOD; +} +?> +</table> +<!-- end of profiling callstack -->
\ No newline at end of file diff --git a/framework/views/sv/profile-summary-firebug.php b/framework/views/sv/profile-summary-firebug.php new file mode 100644 index 0000000..89df929 --- /dev/null +++ b/framework/views/sv/profile-summary-firebug.php @@ -0,0 +1,22 @@ +<script type="text/javascript"> +/*<![CDATA[*/ +if(typeof(console)=='object') +{ + console.group("Profileringsrapport - Sammanställning"); + console.log(" antal total medel min max "); +<?php +foreach($data as $index=>$entry) +{ + $proc=CJavaScript::quote($entry[0]); + $count=sprintf('%5d',$entry[1]); + $min=sprintf('%0.5f',$entry[2]); + $max=sprintf('%0.5f',$entry[3]); + $total=sprintf('%0.5f',$entry[4]); + $average=sprintf('%0.5f',$entry[4]/$entry[1]); + echo "\tconsole.log(\" $count $total $average $min $max {$proc}\");\n"; +} +?> + console.groupEnd(); +} +/*]]>*/ +</script> diff --git a/framework/views/sv/profile-summary.php b/framework/views/sv/profile-summary.php new file mode 100644 index 0000000..61a9bb1 --- /dev/null +++ b/framework/views/sv/profile-summary.php @@ -0,0 +1,41 @@ +<!-- start profiling summary --> +<table class="yiiLog" width="100%" cellpadding="2" style="border-spacing:1px;font:11px Verdana, Arial, Helvetica, sans-serif;background:#EEEEEE;color:#666666;"> + <tr> + <th style="background:black;color:white;" colspan="6"> + Profileringsrapport - Sammanställning + (Tid: <?php echo sprintf('%0.5f',Yii::getLogger()->getExecutionTime()); ?>s, + Minne: <?php echo number_format(Yii::getLogger()->getMemoryUsage()/1024); ?>KB) + </th> + </tr> + <tr style="background-color: #ccc;"> + <th>Procedur</th> + <th>Antal</th> + <th>Total (s)</th> + <th>Medel. (s)</th> + <th>Min. (s)</th> + <th>Max. (s)</th> + </tr> +<?php +foreach($data as $index=>$entry) +{ + $color=($index%2)?'#F5F5F5':'#FFFFFF'; + $proc=CHtml::encode($entry[0]); + $min=sprintf('%0.5f',$entry[2]); + $max=sprintf('%0.5f',$entry[3]); + $total=sprintf('%0.5f',$entry[4]); + $average=sprintf('%0.5f',$entry[4]/$entry[1]); + + echo <<<EOD + <tr style="background:{$color}"> + <td>{$proc}</td> + <td align="center">{$entry[1]}</td> + <td align="center">{$total}</td> + <td align="center">{$average}</td> + <td align="center">{$min}</td> + <td align="center">{$max}</td> + </tr> +EOD; +} +?> +</table> +<!-- end of profiling summary -->
\ No newline at end of file |
