typo3-realurl icon indicating copy to clipboard operation
typo3-realurl copied to clipboard

Mountpoints across domains are not localized

Open jpeters78 opened this issue 7 years ago • 3 comments

Environment: TYPO3 7.6.19 RealUrl 2.2.1

domaina.de (sys_language_uid 0 = de, sys_language_uid 1 = en)

  • Seite 4719 (en: Page) -- Unterseite 4725 (en: Subpage)

domainb.de (sys_language_uid 1 = en, defaultGetVars.L = 1)

  • Page 5072 (Mount Point: 4719) -- Subpage 5096 (Mount Point: 4725)

Without RealUrl the generated links looks like http://domainb.de/index.php?id=4719&L=1&MP=4719-5072 http://domainb.de/index.php?id=4725&L=1&MP=4725-5096

With RealUrl the generated links look like http://domainb.de/en/seite.html http://domainb.de/en/page/unterseite.html

I have already tested under the autoconfiguration but with the same behavior. Before the upgrade, under TYPO3 6.2 and RealUrl 1.13.6, the links were built as expected: http://domainb.de/en/page.html http://domainb.de/en/page/subpage.html

jpeters78 avatar Jun 27 '17 07:06 jpeters78

Question: did you follow exactly language configuration as described in the documentation?

dmitryd avatar Nov 26 '17 08:11 dmitryd

Sorry for the late response, but this issue still exists in RealUrl 2.4.0

Our RealUrl Configuration:

'1' => array (
  'GETvar' => 'L',
  'valueMap' => array (
    'de' => '0',
    'en' => '1',
    'es' => '3',
    'ja' => '5',
  ),
  'noMatch' => 'bypass',
),

TypoScript Configuration domaina.de:

config {
  sys_language_uid = 0
  language = de
  locale_all = de_DE.utf8
  htmlTag_langKey = de
}
[globalVar = GP:L = 0]
config {
  sys_language_uid = 0
  language = de
  locale_all = de_DE.utf8
  htmlTag_langKey = de
}
[global]
[globalVar = GP:L = 1]
config {
  language = en
  locale_all = en_GB.utf-8
  htmlTag_langKey = en_DE
  sys_language_uid = 1
}
[global]

TypoScript Configuration domainb.de

config {
  language = en
  locale_all = en_US.utf-8
  htmlTag_langKey = en-US
  sys_language_uid = 1
}

Page tree domaina.de Seite 4719 (en title: Page) Kind Seite 4724 (en title: Child Page) Enkelkind Seite 5358 (en title: Grandchild Page)

Page tree domainb.de Page 5072 (MP: Seite 4719) Child Page (MP: Kind Seite 4724)

Links without RealUrl: http://domainb.de/index.php?id=4719&L=1&MP=4719-5072 http://domainb.de/index.php?id=4724&L=1&MP=4724-5097 http://domainb.de/index.php?id=5358&L=1&MP=4724-5097

Links with RealUrl: http://domainb.de/en/page.html http://domainb.de/en/page/kind-seite.html http://domainb.de/en/page/kind-seite/enkelkind-seite.html

The pages are called correctly in the english translation. But the speaking urls are mismatched.

jpeters78 avatar Oct 01 '18 10:10 jpeters78

I think I tested it after I saw your report.

The problem here is that your domains have different language setup but you are linking across domains. RealURL always creates links in the context of the current domain. So if L=0 in the url means /en/ for the current domain ("domain A"), than in the encoding context it will mean the same for every other domain in your installation. Now if you encode from another domain ("domain B") and L=0 means /de/ there, than RealURL will use /de/ also for L=0 if you create links for domain A.

I see from your TS that this is exactly the case.

dmitryd avatar Oct 03 '18 11:10 dmitryd