1
0
www.mikescher.com/framework/views/uk/profile-callstack-firebug.php

19 lines
434 B
PHP
Raw Permalink Normal View History

2014-05-13 12:40:42 +02:00
<script type="text/javascript">
/*<![CDATA[*/
if(typeof(console)=='object')
{
console.group("Звіт профілювання стеку викликів");
<?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>