From 2d468d619291c3ec8bbc63f92acc691289d1618d Mon Sep 17 00:00:00 2001 From: Aishwarya Date: Thu, 26 Dec 2019 15:31:14 +0530 Subject: [PATCH] Bug #321 fix: Local Site>> Getting some technical message once user installed the latest package on local site. --- .../site/views/itemform/view.html.php | 23 +++++++++++++------ 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/src/components/com_tjucm/site/views/itemform/view.html.php b/src/components/com_tjucm/site/views/itemform/view.html.php index 98657315..12aa6760 100644 --- a/src/components/com_tjucm/site/views/itemform/view.html.php +++ b/src/components/com_tjucm/site/views/itemform/view.html.php @@ -80,6 +80,15 @@ class TjucmViewItemform extends JViewLegacy */ protected $copyRecId; + /** + * The Title of view + * + * @var String + * + * @since 1.2.4 + */ + protected $title; + /** * Display the view * @@ -292,7 +301,7 @@ protected function _prepareDocument() { $app = Factory::getApplication(); $menus = $app->getMenu(); - $title = null; + $this->title = null; // Because the application sets a default page title, // we need to get it from the menu item itself @@ -307,22 +316,22 @@ protected function _prepareDocument() $this->params->def('page_heading', Text::_('COM_TJUCM_DEFAULT_PAGE_TITLE')); } - $title = $this->params->get('page_title', ''); + $this->title = $this->params->get('page_title', ''); - if (empty($title)) + if (empty($this->title)) { - $title = $app->get('sitename'); + $this->title = $app->get('sitename'); } elseif ($app->get('sitename_pagetitles', 0) == 1) { - $title = Text::sprintf('JPAGETITLE', $app->get('sitename'), $title); + $this->title = Text::sprintf('JPAGETITLE', $app->get('sitename'), $this->title); } elseif ($app->get('sitename_pagetitles', 0) == 2) { - $title = Text::sprintf('JPAGETITLE', $title, $app->get('sitename')); + $this->title = Text::sprintf('JPAGETITLE', $this->title, $app->get('sitename')); } - $this->document->setTitle($title); + $this->document->setTitle($this->title); if ($this->params->get('menu-meta_description')) {