Commit cb8cc9f6 by Carsten Brandt

Fix error page alignment problems in various browsers

issue #418
parent 1d3df026
......@@ -16,7 +16,7 @@ $context = $this->context;
<li class="<?php if (!$context->isCoreFile($file) || $index === 1) echo 'application'; ?> call-stack-item">
<div class="element-wrap">
<div class="element">
<span class="line-number"><?php echo (int)$index; ?>.</span>
<span class="item-number"><?php echo (int)$index; ?>.</span>
<span class="text"><?php if ($file !== null) echo 'in ' . $context->htmlEncode($file); ?></span>
<?php if ($method !== null): ?>
<span class="call">
......@@ -36,7 +36,12 @@ $context = $this->context;
<?php endfor; ?>
<div class="code">
<span class="lines"><?php for ($i = $begin; $i <= $end; ++$i) echo (int)$i . '<br/>'; ?></span>
<pre><?php for ($i = $begin; $i <= $end; ++$i) echo $context->htmlEncode($lines[$i]); ?></pre>
<pre><?php
// fill empty lines with a whitespace to avoid rendering problems in opera
for ($i = $begin; $i <= $end; ++$i) {
echo (trim($lines[$i]) == '') ? " \n" : $context->htmlEncode($lines[$i]);
}
?></pre>
</div>
</div>
<?php endif; ?>
......
......@@ -169,7 +169,7 @@ html,body{
color: #000;
text-shadow: 0 1px 0 #cacaca;
}
.call-stack ul li .line-number{
.call-stack ul li .item-number{
width: 45px;
display: inline-block;
}
......@@ -204,9 +204,8 @@ html,body{
background-color: #ffebeb;
position: absolute;
width: 100%;
height: 20px;
height: 18px;
z-index: 100;
margin-top: 15px;
}
.call-stack ul li .hover-line{
background: none;
......@@ -216,8 +215,8 @@ html,body{
}
.call-stack ul li .code{
min-width: 860px; /* 960px - 50px * 2 */
margin: 0 auto;
padding: 15px 50px;
margin: 15px auto;
padding: 0 50px;
position: relative;
}
.call-stack ul li .code .lines{
......@@ -226,6 +225,8 @@ html,body{
left: 50px;
line-height: 18px;
font-size: 14px;
vertical-align: middle;
text-align: right;
font-family: Consolas, Courier New, monospace;
color: #aaa;
}
......@@ -235,6 +236,7 @@ html,body{
left: 50px;
line-height: 18px;
font-size: 14px;
vertical-align: middle;
font-family: Consolas, Courier New, monospace;
display: inline;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment