openrat-cms

# OpenRat Content Management System
git clone http://git.code.weiherhei.de/openrat-cms.git
Log | Files | Refs

commit 53362f6746ddcc1b35506223193d42caeb8a8eb0
parent 53f1c056ebf19d6799b81a58df9d36c6da001f33
Author: Jan Dankert <develop@jandankert.de>
Date:   Thu, 12 Dec 2019 22:26:47 +0100

Fix: linked pages must be loaded before creating a link to them.

Diffstat:
modules/cms-macros/macro/LanguageLinksForPage.class.php | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/modules/cms-macros/macro/LanguageLinksForPage.class.php b/modules/cms-macros/macro/LanguageLinksForPage.class.php @@ -56,6 +56,7 @@ class LanguageLinksForPage extends Macro $targetPage->publisher = $this->page->publisher; $targetPage->languageid = $lid; $targetPage->modelid = $this->page->modelid; + $targetPage->load(); $link = $this->page->publisher->linkToObject( $this->page, $targetPage ); echo '<li><a hreflang="'.$language->isoCode.'" href="'.$link.'">'.strtolower($language->isoCode).'</a></li>';