From 4580d595cce3c282a749a10ab29e040766f5c4ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bjo=CC=88rn=20Fromme?= Date: Tue, 14 Aug 2018 10:43:26 +0200 Subject: [PATCH] Render custom canonical tag --- .../ext/ep_theme/Configuration/TypoScript/Page/Main.ts | 10 ++++++++++ .../ep_theme/Configuration/TypoScript/constants.txt | 2 ++ 2 files changed, 12 insertions(+) diff --git a/web/typo3conf/ext/ep_theme/Configuration/TypoScript/Page/Main.ts b/web/typo3conf/ext/ep_theme/Configuration/TypoScript/Page/Main.ts index b4c9f110..256f33a2 100644 --- a/web/typo3conf/ext/ep_theme/Configuration/TypoScript/Page/Main.ts +++ b/web/typo3conf/ext/ep_theme/Configuration/TypoScript/Page/Main.ts @@ -1,3 +1,10 @@ +tmp.canonical = TEXT +tmp.canonical { + typolink.parameter.data = TSFE:id + typolink.returnLast = url + wrap = +} + page = PAGE page { meta { @@ -139,6 +146,9 @@ page { ) headerData.999.stdWrap.if.isTrue = {$plugin.tx_eptheme.settings.googleTagManagerId} + + headerData.100 < tmp.canonical + headerData.100.insertData = 1 } [applicationContext = Development] diff --git a/web/typo3conf/ext/ep_theme/Configuration/TypoScript/constants.txt b/web/typo3conf/ext/ep_theme/Configuration/TypoScript/constants.txt index 9c7a2b1a..804a4a0b 100644 --- a/web/typo3conf/ext/ep_theme/Configuration/TypoScript/constants.txt +++ b/web/typo3conf/ext/ep_theme/Configuration/TypoScript/constants.txt @@ -106,6 +106,8 @@ plugin.tx_eptheme { googleMapsJsApiUrl = https://maps.googleapis.com/maps/api/js?key=AIzaSyDDOforD1O_j4xXy2nJybC2yQqbUAw9ClY # cat=eptheme/300/120; type=string; label=Google Maps Js API Url googleMapsApiKey = AIzaSyDDOforD1O_j4xXy2nJybC2yQqbUAw9ClY + # cat=eptheme/300/130; type=string; label=Canonical base URL/Domain + canonicalBaseUrl = https://www.ep-reisen.de # cat=eptheme.events/700/100; type=string; label=Event date day from eventDateDayFrom =