<?php

/**
 * OntoWiki error template
 *
 * @author Norman Heino <norman.heino@gmail.com>
 * @version $Id: error.phtml 3331 2009-06-16 19:25:43Z norman.heino $
 */

?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><?php echo $this->heading ?></title>
<style type="text/css">
body {
    font-family: sans-serif;
    line-height: 1.5;
    background-color: #eff9ff;
}

.info {
    margin: 0.5% 10%;
    border: 1px solid #aaa;
    padding: 1%;
    background-color: #f9f9f9;
}

.error {
    margin: 0.5% 10%;
    border: 1px solid #f00;
    padding: 1%;
    background-color: #fcc;
}
</style>
</head>
<body>
<div class="<?php echo $this->errorType ?>">
<h1><?php echo $this->heading ?>
<?php if (isset($this->code)): ?>
 (<?php echo $this->code ?>)
<?php endif; ?>
</h1>
<details>
<summary><?php echo $this->escape($this->errorText) ?></summary>
<?php if (isset($this->exceptionType)): ?>
<p><code><?php echo $this->exceptionType ?></code></p>
<?php endif; ?>
<p>
<?php if (isset($this->exceptionFile)): ?>
<code><?php echo $this->exceptionFile ?></code>
<?php endif; ?>
<?php if (isset($this->stacktrace)): ?>
<br/ ><code><?php echo $this->stacktrace ?></code>
<?php endif; ?>
</p>
</details>
<p>
<?php if(isset($_SERVER['HTTP_REFERER'])){ ?>
     <a href="<?php echo $_SERVER['HTTP_REFERER']; ?>">back</a>&nbsp;
<?php } ?>
<a href="<?php echo $this->urlBase; ?>">home</a>
</p>
</div>
</body>
</html>
