Files
gallery3/modules/gallery/views/error_user.html.php
Bharat Mediratta 41ca2b0195 Rework our exception framework to fit into Kohana's model better.
Instead of overwriting Kohana_Exception::handle() (which we were doing
in MY_Kohana_Exception) we instead use their existing template system.

gallery/views/kohana/error.php overrides system/views/kohana/error.php
and is the standard error template for all exceptions.  Our version of
error.php figures out the appropriate view based on context (cli,
authenticated admin, guest viewing a 404, guest viewing a system
error) and delegates appropriately.  Each delegated view has a narrow
responsibility.

This paves the way for us to add new error views per module.  For
example, the rest module will define its own template in
Rest_Exception and then its exceptions can be rendered the way that it
wants (json encoded, in that case).
2010-06-19 14:07:32 -07:00

43 lines
1.1 KiB
PHP

<?php defined("SYSPATH") or die("No direct script access.") ?>
<? if (!function_exists("t")) { function t($msg) { return $msg; } } ?>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<style type="text/css">
body {
background: #fff;
font-size: 14px;
line-height: 130%;
}
div.big_box {
padding: 10px;
background: #eee;
border: solid 1px #ccc;
font-family: sans-serif;
color: #111;
width: 60em;
margin: 20px auto;
}
div#framework_error {
text-align: center;
}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title><?= t("Something went wrong!") ?></title>
</head>
<body>
<div class="big_box" id="framework_error">
<h1>
<?= t("Dang... Something went wrong!") ?>
</h1>
<h2>
<?= t("We tried really hard, but it's broken.") ?>
</h2>
<p>
<?= t("Talk to your Gallery administrator for help fixing this!") ?>
</p>
</div>
</body>
</html>