} } } // Need to filter the default value as well $template->template = InputFilter::getInstance()->clean($template->template, 'cmd'); // Fallback template if (!empty($template->parent)) { if (!is_file(JPATH_THEMES . '/' . $template->template . '/index.php')) { if (!is_file(JPATH_THEMES . '/' . $template->parent . '/index.php')) { public function render(\Throwable $error): string { $app = Factory::getApplication(); // Get the current template from the application $template = $app->getTemplate(true); // Push the error object into the document $this->getDocument()->setError($error); // Add registry file for the template asset 'subject' => $app, 'document' => $renderer->getDocument(), ]) ); $data = $renderer->render($error); // If nothing was rendered, just use the message from the Exception if (empty($data)) { $data = $error->getMessage(); } * @since 3.10.0 */ public static function handleException(\Throwable $error) { static::logException($error); static::render($error); } /** * Render the error page based on an exception. * ); // Trigger the onError event. $this->dispatchEvent('onError', $event); ExceptionHandler::handleException($event->getError()); } // Trigger the onBeforeRespond event. $this->dispatchEvent( 'onBeforeRespond',// Set the application as global app\Joomla\CMS\Factory::$application = $app;// Execute the application.$app->execute(); // ... die die();}// Run the application - All executable code should be triggered through this filerequire_once __DIR__ . '/includes/app.php'; * * @return string The title of the group * * @since 3.5 */ public static function getGroupTitle($groupId) { // Cast as integer until method is typehinted. $groupId = (int) $groupId; // Fetch the group title from the database */ public function loadClass($class) { if ($file = $this->findFile($class)) { $includeFile = self::$includeFile; $includeFile($file); return true; } return null; * * @since 3.4 */ public function loadClass($class) { if ($result = $this->loader->loadClass($class)) { \JLoader::applyAliasFor($class); } return $result; } if ($this->_authLevels === null) { $this->_authLevels = []; } if (empty($this->_authLevels)) { $this->_authLevels = Access::getAuthorisedViewLevels($this->id); } return $this->_authLevels; } { if (static::$plugins !== null) { return static::$plugins; } $levels = Factory::getUser()->getAuthorisedViewLevels(); /** @var \Joomla\CMS\Cache\Controller\CallbackController $cache */ $cache = Factory::getCache('com_plugins', 'callback'); $loader = function () use ($levels) { * @since 1.5 */ public static function getPlugin($type, $plugin = null) { $result = []; $plugins = static::load(); // Find the correct plugin(s) to return. if (!$plugin) { foreach ($plugins as $p) { // Is this the right plugin? if ($user->guest) { $guestUsergroup = ComponentHelper::getParams('com_users')->get('guest_usergroup', 1); $user->groups = [$guestUsergroup]; } if ($plugin = PluginHelper::getPlugin('system', 'languagefilter')) { $pluginParams = new Registry($plugin->params); $this->setLanguageFilter(true); $this->setDetectBrowser($pluginParams->get('detect_browser', 1) == 1); } * @since 3.2 */ protected function doExecute() { // Initialise the application $this->initialiseApp(); // Mark afterInitialise in the profiler. JDEBUG ? $this->profiler->mark('afterInitialise') : null; // Route the application $this->sanityCheckSystemVariables(); $this->setupLogging(); $this->createExtensionNamespaceMap(); // Perform application routines. $this->doExecute(); // If we have an application document object, render it. if ($this->document instanceof \Joomla\CMS\Document\Document) { // Render the application output. $this->render();// Set the application as global app\Joomla\CMS\Factory::$application = $app;// Execute the application.$app->execute(); // ... die die();}// Run the application - All executable code should be triggered through this filerequire_once __DIR__ . '/includes/app.php';|
[2/2]
Error
|
|---|
Error:
Attempt to assign property "template" on null
at /var/www/tintucvietduc.net/libraries/src/Application/SiteApplication.php:501
at Joomla\CMS\Application\SiteApplication->getTemplate()
(/var/www/tintucvietduc.net/libraries/src/Error/Renderer/HtmlRenderer.php:50)
at Joomla\CMS\Error\Renderer\HtmlRenderer->render()
(/var/www/tintucvietduc.net/libraries/src/Exception/ExceptionHandler.php:142)
at Joomla\CMS\Exception\ExceptionHandler::render()
(/var/www/tintucvietduc.net/libraries/src/Exception/ExceptionHandler.php:76)
at Joomla\CMS\Exception\ExceptionHandler::handleException()
(/var/www/tintucvietduc.net/libraries/src/Application/CMSApplication.php:334)
at Joomla\CMS\Application\CMSApplication->execute()
(/var/www/tintucvietduc.net/includes/app.php:58)
at require_once('/var/www/tintucvietduc.net/includes/app.php')
(/var/www/tintucvietduc.net/index.php:51)
|
|
[1/2]
ParseError
|
|---|
ParseError:
syntax error, unexpected token "public"
at /var/www/tintucvietduc.net/libraries/src/Access/Access.php:794
at Composer\Autoload\{closure}()
(/var/www/tintucvietduc.net/libraries/vendor/composer/ClassLoader.php:427)
at Composer\Autoload\ClassLoader->loadClass()
(/var/www/tintucvietduc.net/libraries/src/Autoload/ClassLoader.php:59)
at Joomla\CMS\Autoload\ClassLoader->loadClass()
(/var/www/tintucvietduc.net/libraries/src/User/User.php:474)
at Joomla\CMS\User\User->getAuthorisedViewLevels()
(/var/www/tintucvietduc.net/libraries/src/Plugin/PluginHelper.php:259)
at Joomla\CMS\Plugin\PluginHelper::load()
(/var/www/tintucvietduc.net/libraries/src/Plugin/PluginHelper.php:109)
at Joomla\CMS\Plugin\PluginHelper::getPlugin()
(/var/www/tintucvietduc.net/libraries/src/Application/SiteApplication.php:573)
at Joomla\CMS\Application\SiteApplication->initialiseApp()
(/var/www/tintucvietduc.net/libraries/src/Application/SiteApplication.php:237)
at Joomla\CMS\Application\SiteApplication->doExecute()
(/var/www/tintucvietduc.net/libraries/src/Application/CMSApplication.php:304)
at Joomla\CMS\Application\CMSApplication->execute()
(/var/www/tintucvietduc.net/includes/app.php:58)
at require_once('/var/www/tintucvietduc.net/includes/app.php')
(/var/www/tintucvietduc.net/index.php:51)
|