| <?php |
| /** |
| * Licensed to the Apache Software Foundation (ASF) under one |
| * or more contributor license agreements. See the NOTICE file |
| * distributed with this work for additional information |
| * regarding copyright ownership. The ASF licenses this file |
| * to you under the Apache License, Version 2.0 (the |
| * "License"); you may not use this file except in compliance |
| * with the License. You may obtain a copy of the License at |
| * |
| * https://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, |
| * software distributed under the License is distributed on an |
| * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| * KIND, either express or implied. See the License for the |
| * specific language governing permissions and limitations |
| * under the License. |
| */ |
| ?> |
| <h1><?php echo $this->translate('An error occurred') ?></h1> |
| <h2><?php echo $this->message ?></h2> |
| |
| <?php if (isset($this->display_exceptions) && $this->display_exceptions): ?> |
| |
| <?php if(isset($this->exception) && $this->exception instanceof Exception): ?> |
| <hr/> |
| <h2><?php echo $this->translate('Additional information') ?>:</h2> |
| <h3><?php echo get_class($this->exception); ?></h3> |
| <dl> |
| <dt><?php echo $this->translate('File') ?>:</dt> |
| <dd> |
| <pre class="prettyprint linenums"><?php echo $this->exception->getFile() ?>:<?php echo $this->exception->getLine() ?></pre> |
| </dd> |
| <dt><?php echo $this->translate('Message') ?>:</dt> |
| <dd> |
| <pre class="prettyprint linenums"><?php echo $this->escapeHtml($this->exception->getMessage()) ?></pre> |
| </dd> |
| <dt><?php echo $this->translate('Stack trace') ?>:</dt> |
| <dd> |
| <pre class="prettyprint linenums"><?php echo $this->escapeHtml($this->exception->getTraceAsString()) ?></pre> |
| </dd> |
| </dl> |
| <?php |
| $e = $this->exception->getPrevious(); |
| $icount = 0; |
| if ($e) : |
| ?> |
| <hr/> |
| <h2><?php echo $this->translate('Previous exceptions') ?>:</h2> |
| <ul class="unstyled"> |
| <?php while($e) : ?> |
| <li> |
| <h3><?php echo get_class($e); ?></h3> |
| <dl> |
| <dt><?php echo $this->translate('File') ?>:</dt> |
| <dd> |
| <pre class="prettyprint linenums"><?php echo $e->getFile() ?>:<?php echo $e->getLine() ?></pre> |
| </dd> |
| <dt><?php echo $this->translate('Message') ?>:</dt> |
| <dd> |
| <pre class="prettyprint linenums"><?php echo $this->escapeHtml($e->getMessage()) ?></pre> |
| </dd> |
| <dt><?php echo $this->translate('Stack trace') ?>:</dt> |
| <dd> |
| <pre class="prettyprint linenums"><?php echo $this->escapeHtml($e->getTraceAsString()) ?></pre> |
| </dd> |
| </dl> |
| </li> |
| <?php |
| $e = $e->getPrevious(); |
| $icount += 1; |
| if ($icount >= 50) { |
| echo "<li>There may be more exceptions, but we have no enough memory to proccess it.</li>"; |
| break; |
| } |
| endwhile; |
| ?> |
| </ul> |
| <?php endif; ?> |
| |
| <?php else: ?> |
| |
| <h3><?php echo $this->translate('No Exception available') ?></h3> |
| |
| <?php endif ?> |
| |
| <?php endif ?> |