Project

General

Profile

Actions

Bug #102339

open

Typo3 11 PageLinkBuilder does not take shortcut_mode and target of translated page into account

Added by Sruthi Kumar G 6 months ago. Updated about 1 month ago.

Status:
New
Priority:
Should have
Assignee:
-
Category:
Content Rendering
Target version:
Start date:
2023-11-07
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
11
PHP Version:
7.4
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

I have edited shortcut mode and target page of translated page. But in menu the link rendered is based on default language page properties.

In this case, it's always page id 29, not 1117.


Files

tempsnip.png (44.7 KB) tempsnip.png Sruthi Kumar G, 2023-11-07 12:34
Actions #1

Updated by Manfred Egger 6 months ago

Same problem here. One of our customer heavily relies on different shortcut targets per language and after upgrading to TYPO3 11 (from 8.7) it doesn't work anymore.

As far as I could see it's not only restricted to MenuProcessor. It seems to be a problem in the hole PageLinkBuilder. If you add a link to such a shortcut page e.g. in a text content element, the link is also wrong.

Actions #2

Updated by Sruthi Kumar G 6 months ago

  • Subject changed from Typo3 11 menu processor does not take shortcut_mode and target of translated page into account to Typo3 11 PageLinkBuilder does not take shortcut_mode and target of translated page into account
Actions #3

Updated by Sruthi Kumar G 6 months ago

Yes, this seems to be an issue with PageLinkBuilder.I added a fix I found in a similar issue and it's fixed for now. But would need a permanent solution rather than a unreliable hotfix.

Actions #4

Updated by Riccardo De Contardi about 1 month ago

I am unsure about how to reproduce this one.

I have done the following test:

Prerequisites

  • TYPO3 13.1.0-dev (latest master)
  • two languages: Italian (0) and English (1)
  • Let's say that I have
    • a page in Italian called "TEST 1"
    • another page "TEST 2" which has been translated "TEST 2 ENG"
    • a menu built in TypoScript:
page.20 = HMENU

page.20 {
  1 = TMENU
  1.expAll = 1
  1.wrap = <ul>|</ul>
  1.NO.wrapItemAndSub = <li>|</li> 
  1.CUR = 1
  1.CUR.wrapItemAndSub = <li> <strong>current: - </strong>|</li> 

  1.ACT = 1
  1.ACT.wrapItemAndSub = <li> <strong>active: - </strong>|</li>   

  2 < .1
  3 < .1
}

The test

  1. Create a new page "T102339", type: shortcut page in Italian (main language)
    1. Shortcut Mode: selected page
    2. Shortcut Target: "TEST1"
  2. Translate "T102339" into english ""T102339 ENG"
  3. Edit it
    1. Shortcut Target: Translation behavior: custom value ; select the target "TEST2 ENG"
  4. save and visit the frontend

Results

  1. in the ITALIAN frontend version of the site, the menu item for the shortcut reads "T102339" and it leads to "TEST1"
  2. in the ENGLISH frontend version of the site, the menu item for the shortcut reads "T102339 ENG" and it leads to "TEST2 ENG"

Is this the expected behavior? Or is a different test necessary?

Additional notes

I've found that the interface for the translated shortcut target is a bit confusing: it lets me assign a different target page, but with the option "translation behavior": Value of default language still selected, so the different target page is not taken into account at all!

Actions #5

Updated by Manfred Egger about 1 month ago

It seems that this bug is fixed since TYPO3 12 LTS at least for the HMENU.

The bug is still present in "normal" links. If i create a link in a text content element to the shortcut page, the link on the translated page points to the wrong place. Tested with TYPO3 12.4.13

Actions

Also available in: Atom PDF