From eb152305961506deea090197060de518dd5bb555 Mon Sep 17 00:00:00 2001 From: Marcel Werk Date: Mon, 20 Jun 2016 18:54:27 +0200 Subject: [PATCH] Fixed issues with multilingual page titles --- com.woltlab.wcf/templates/cms.tpl | 7 +++++-- wcfsetup/install/files/lib/data/page/PageCache.class.php | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/com.woltlab.wcf/templates/cms.tpl b/com.woltlab.wcf/templates/cms.tpl index 55111b784a..7c803e0160 100644 --- a/com.woltlab.wcf/templates/cms.tpl +++ b/com.woltlab.wcf/templates/cms.tpl @@ -1,6 +1,9 @@ +{if !$__wcf->isLandingPage()} + {capture assign='pageTitle'}{$content[title]}{/capture} + {capture assign='contentTitle'}{$content[title]}{/capture} +{/if} + {capture assign='headContent'} - - {if $page->isMultilingual} {foreach from=$page->getPageLanguages() item='pageLanguage'} {if $pageLanguage->getLanguage()} diff --git a/wcfsetup/install/files/lib/data/page/PageCache.class.php b/wcfsetup/install/files/lib/data/page/PageCache.class.php index 1213cb748c..46229ee47b 100644 --- a/wcfsetup/install/files/lib/data/page/PageCache.class.php +++ b/wcfsetup/install/files/lib/data/page/PageCache.class.php @@ -94,7 +94,7 @@ class PageCache extends SingletonFactory { return $this->cache['pageTitles'][$pageID][$languageID]; } - return $this->cache['pageTitles'][$pageID][WCF::getUser()->getLanguage()->languageID]; + return $this->cache['pageTitles'][$pageID][WCF::getLanguage()->languageID]; } else { return $this->cache['pageTitles'][$pageID][0]; -- 2.20.1