1
|
<?php
|
2
|
/**
|
3
|
* @package yoo_bento
|
4
|
* @author YOOtheme http://www.yootheme.com
|
5
|
* @copyright Copyright (C) YOOtheme GmbH
|
6
|
* @license http://www.gnu.org/licenses/gpl.html GNU/GPL
|
7
|
*/
|
8
|
|
9
|
// no direct access
|
10
|
defined('_JEXEC') or die('Restricted access');
|
11
|
|
12
|
// get warp
|
13
|
$warp = require(__DIR__.'/warp.php');
|
14
|
|
15
|
// set messages
|
16
|
$title = $this->title;
|
17
|
$error = $this->error->getCode();
|
18
|
$message = $this->error->getMessage();
|
19
|
|
20
|
// set 404 messages
|
21
|
if ($error == '404') {
|
22
|
$title = JText::_('TPL_WARP_404_PAGE_TITLE');
|
23
|
$message = JText::sprintf('TPL_WARP_404_PAGE_MESSAGE', JURI::root(false), $warp['config']->get('site_name'));
|
24
|
}
|
25
|
|
26
|
// render error layout
|
27
|
echo $warp['template']->render('error', compact('title', 'error', 'message'));
|