[ Index ] |
PHP Cross Reference of Joomla 4.2.2 documentation |
[Summary view] [Print] [Text view]
1 <?php 2 3 /** 4 * @package Joomla.Site 5 * @subpackage Template.system 6 * 7 * @copyright (C) 2006 Open Source Matters, Inc. <https://www.joomla.org> 8 * @license GNU General Public License version 2 or later; see LICENSE.txt 9 */ 10 11 defined('_JEXEC') or die; 12 13 use Joomla\CMS\Language\Text; 14 use Joomla\CMS\Uri\Uri; 15 16 /** @var Joomla\CMS\Document\ErrorDocument $this */ 17 18 if (!isset($this->error)) { 19 $this->error = new Exception(Text::_('JERROR_ALERTNOAUTHOR')); 20 $this->debug = false; 21 } 22 23 // Load template CSS file 24 $this->getWebAssetManager()->registerAndUseStyle('template.system.error', 'media/system/css/system-site-error.css'); 25 26 if ($this->direction === 'rtl') { 27 $this->getWebAssetManager()->registerAndUseStyle('template.system.error_rtl', 'media/system/css/system-site-error_rtl.css'); 28 } 29 30 // Set page title 31 $this->setTitle($this->error->getCode() . ' - ' . htmlspecialchars($this->error->getMessage(), ENT_QUOTES, 'UTF-8')); 32 33 ?> 34 <!DOCTYPE html> 35 <html lang="<?php echo $this->language; ?>" dir="<?php echo $this->direction; ?>"> 36 <head> 37 <jdoc:include type="metas" /> 38 <jdoc:include type="styles" /> 39 <jdoc:include type="scripts" /> 40 </head> 41 <body> 42 <div class="error"> 43 <div id="outline"> 44 <div id="errorboxoutline"> 45 <div id="errorboxheader"><?php echo $this->error->getCode(); ?> - <?php echo htmlspecialchars($this->error->getMessage(), ENT_QUOTES, 'UTF-8'); ?></div> 46 <div id="errorboxbody"> 47 <p><strong><?php echo Text::_('JERROR_LAYOUT_NOT_ABLE_TO_VISIT'); ?></strong></p> 48 <ol> 49 <li><?php echo Text::_('JERROR_LAYOUT_AN_OUT_OF_DATE_BOOKMARK_FAVOURITE'); ?></li> 50 <li><?php echo Text::_('JERROR_LAYOUT_SEARCH_ENGINE_OUT_OF_DATE_LISTING'); ?></li> 51 <li><?php echo Text::_('JERROR_LAYOUT_MIS_TYPED_ADDRESS'); ?></li> 52 <li><?php echo Text::_('JERROR_LAYOUT_YOU_HAVE_NO_ACCESS_TO_THIS_PAGE'); ?></li> 53 <li><?php echo Text::_('JERROR_LAYOUT_REQUESTED_RESOURCE_WAS_NOT_FOUND'); ?></li> 54 <li><?php echo Text::_('JERROR_LAYOUT_ERROR_HAS_OCCURRED_WHILE_PROCESSING_YOUR_REQUEST'); ?></li> 55 </ol> 56 <p><strong><?php echo Text::_('JERROR_LAYOUT_PLEASE_TRY_ONE_OF_THE_FOLLOWING_PAGES'); ?></strong></p> 57 <ul> 58 <li><a href="<?php echo Uri::root(true); ?>/index.php"><?php echo Text::_('JERROR_LAYOUT_HOME_PAGE'); ?></a></li> 59 </ul> 60 <p><?php echo Text::_('JERROR_LAYOUT_PLEASE_CONTACT_THE_SYSTEM_ADMINISTRATOR'); ?></p> 61 <div id="techinfo"> 62 <p> 63 <?php echo htmlspecialchars($this->error->getMessage(), ENT_QUOTES, 'UTF-8'); ?> 64 <?php if ($this->debug) : ?> 65 <br><?php echo htmlspecialchars($this->error->getFile(), ENT_QUOTES, 'UTF-8');?>:<?php echo $this->error->getLine(); ?> 66 <?php endif; ?> 67 </p> 68 <?php if ($this->debug) : ?> 69 <div> 70 <?php echo $this->renderBacktrace(); ?> 71 <?php // Check if there are more Exceptions and render their data as well ?> 72 <?php if ($this->error->getPrevious()) : ?> 73 <?php $loop = true; ?> 74 <?php // Reference $this->_error here and in the loop as setError() assigns errors to this property and we need this for the backtrace to work correctly ?> 75 <?php // Make the first assignment to setError() outside the loop so the loop does not skip Exceptions ?> 76 <?php $this->setError($this->_error->getPrevious()); ?> 77 <?php while ($loop === true) : ?> 78 <p><strong><?php echo Text::_('JERROR_LAYOUT_PREVIOUS_ERROR'); ?></strong></p> 79 <p> 80 <?php echo htmlspecialchars($this->_error->getMessage(), ENT_QUOTES, 'UTF-8'); ?> 81 <br><?php echo htmlspecialchars($this->_error->getFile(), ENT_QUOTES, 'UTF-8');?>:<?php echo $this->_error->getLine(); ?> 82 </p> 83 <?php echo $this->renderBacktrace(); ?> 84 <?php $loop = $this->setError($this->_error->getPrevious()); ?> 85 <?php endwhile; ?> 86 <?php // Reset the main error object to the base error ?> 87 <?php $this->setError($this->error); ?> 88 <?php endif; ?> 89 </div> 90 <?php endif; ?> 91 </div> 92 </div> 93 </div> 94 </div> 95 </div> 96 97 <jdoc:include type="modules" name="debug" style="none" /> 98 </body> 99 </html>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Wed Sep 7 05:41:13 2022 | Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer |