#109398Copying page or content with localized IRRE children results in wrong pid and incorrect localization references
Description
When copying a page or content element that contains inline (IRRE) child records with translations, TYPO3 does not correctly update the pid and localization references of the translated child records.
This leads to inconsistent data where:
- localized IRRE child records keep the original pid (from the source page)
- localization references (l10n_parent) may still point to the original records instead of the newly copied ones
This behavior breaks backend rendering when using pid-based constraints (e.g. ###CURRENT_PID### in TCA) and results in missing labels or incorrect data relations.
Steps to Reproduce:
1. Create a custom IRRE child table with proper localization fields:
– sys_language_uid
– l10n_parent
– l10n_source
2. Create a content element (tt_content) that uses this IRRE relation.
3. Add several child records (default language).
4. Translate the content element and its IRRE child records (e.g. into language 1).
5. Copy:
a) the whole page OR
b) the content element to another page
6. Inspect the database, IRRE table
Behavior:
- Default language IRRE records are copied correctly and receive the new pid
- Translated IRRE records:
– keep the original pid (from the source page)
– may still reference original records via l10n_parent
This results in:
- broken localization chains
- backend issues (e.g. “missing label”)
- inconsistent data integrity
- IRRE localization becomes unreliable when content is copied
- Backend UI may break due to missing references
- Developers need to implement custom DataHandler hooks to fix pid and references after copy
This affects custom extensions using IRRE with localization.
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.
Fix this issue
Start the commit message of your patch with this. Add what the patch does, and the versions it goes to in "Releases:". How to create a patch
- Commit message
-
[BUGFIX] Copying page or content with localized IRRE children results in wrong pid and incorrect localization references Resolves: #109398 Releases: main
History 3
-
Garvin Hicking changed category <span data-processor="relativetime" data-value="2026-03-27T16:52:13+00:00" > 03/27/26, 16:52 </span>
-
Slavomir Karolyi commented <span data-processor="relativetime" data-value="2026-05-28T13:06:50+00:00" > 05/28/26, 13:06 </span>
-
Georg Ringer commented and changed status
NewNeeds Feedback <span data-processor="relativetime" data-value="2026-11-04T15:08:58+00:00" > 11/04/26, 15:08 </span>Hi,
I tried to reproduce this on current
main(15.0-dev) and on13.4(9890db99925) with a functional test, but could not reproduce the wrongpid/l10n_parentso far.Setup (EXT:core test fixture
test_irre_foreignfield,tt_content.tx_testirreforeignfield_hotelsis the inline field,tx_testirreforeignfield_hotelthe child table, localized viasys_language_uidandl18n_parent):table uid pid sys_language_uid l10n_parent note pages 2 1 0 0 source page pages 3 1 0 0 target page tt_content 1 2 0 0 default CE, inline field “1,2” tx_testirreforeignfield_hotel 1 2 0 0 default child, parentid = 1 tx_testirreforeignfield_hotel 2 2 1 1 translated child, parentid = 1 Action: copy page 2 into page 3 (
$cmd['pages'][2]['copy'] = 3).Result after the copy:
table uid pid sys_language_uid l10n_parent note pages 4 3 0 0 copied page tt_content 2 4 0 0 copy of CE 1 tx_testirreforeignfield_hotel 3 4 0 0 copy of hotel 1 tx_testirreforeignfield_hotel 4 4 0 3 copy of hotel 2, points to the new hotel 3 tx_testirreforeignfield_hotel 1 2 0 0 unchanged tx_testirreforeignfield_hotel 2 2 1 1 unchanged The copied translated child gets the new
pidand itsl18n_parentpoints to the copied default child. Only thesys_language_uidchanges (1 to 0), because inline children are aligned to the language of their parent, which is the default language CE here.I also tried the variant where the translated content element has its own translated child. A page copy only copies the default language content elements, so the translated CE and its child stay untouched on the source page, with no broken references.
What I did not cover: copying a single content element to another page, copying together with the translated content element, and a child table using
###CURRENT_PID###in its TCA.Could you provide the TCA of the child table and the inline field, the exact copy action (page or content element, “Copy” or “Copy to other language”), and the affected records before and after the copy (uid, pid, sys_language_uid, l10n_parent, parentid)? Without that I can not reproduce it.
Hi,
I just wanted to ask if there has been any progress on this issue or if there are any updates?
Thank you very much.