@@ 271-282 (lines=12) @@ | ||
268 | * @return void |
|
269 | */ |
|
270 | function elgg_error_page_handler($hook, $type, $result, $params) { |
|
271 | if (elgg_view_exists("errors/$type")) { |
|
272 | $title = elgg_echo("error:$type:title"); |
|
273 | if ($title == "error:$type:title") { |
|
274 | // use default if there is no title for this error type |
|
275 | $title = elgg_echo("error:default:title"); |
|
276 | } |
|
277 | ||
278 | $content = elgg_view("errors/$type", $params); |
|
279 | } else { |
|
280 | $title = elgg_echo("error:default:title"); |
|
281 | $content = elgg_view("errors/default", $params); |
|
282 | } |
|
283 | ||
284 | $httpCodes = array( |
|
285 | '400' => 'Bad Request', |
@@ 636-643 (lines=8) @@ | ||
633 | $params = elgg_trigger_plugin_hook('output:before', 'layout', null, $param_array); |
|
634 | ||
635 | // check deprecated location |
|
636 | if (elgg_view_exists("canvas/layouts/$layout_name")) { |
|
637 | elgg_deprecated_notice("canvas/layouts/$layout_name is deprecated by page/layouts/$layout_name", 1.8); |
|
638 | $output = elgg_view("canvas/layouts/$layout_name", $params); |
|
639 | } elseif (elgg_view_exists("page/layouts/$layout_name")) { |
|
640 | $output = elgg_view("page/layouts/$layout_name", $params); |
|
641 | } else { |
|
642 | $output = elgg_view("page/layouts/default", $params); |
|
643 | } |
|
644 | ||
645 | return elgg_trigger_plugin_hook('output:after', 'layout', $params, $output); |
|
646 | } |