Logo
Explore Help
Sign In
stian/gallery3
1
0
Fork 0
You've already forked gallery3
mirror of https://github.com/Pathduck/gallery3.git synced 2026-06-10 05:29:13 -04:00
Code Issues Actions Packages Projects Releases Wiki Activity
Files
456d54ea2dccbe55a2efd89ecb4bde29fb91b619
gallery3/modules/gallery/views/error_cli.txt.php

4 lines
98 B
PHP
Raw Normal View History

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 13:52:48 -07:00
<?php defined("SYSPATH") or die("No direct script access.") ?>
<?= Kohana_Exception::text($e) ?>
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.25.3 Page: 52ms Template: 3ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API