#106317Form element content element: tranlated element not used and variant condition on site language doesn’t work
Description
I inserted a form element type content element on a form. Default language is german, additional language is english. On the english page I still got the german element in frontend. I tried to solve that via a variant condition, but did not work:
label: Inhaltselement
properties:
contentElementUid: '49787'
type: ContentElement
identifier: contentelement-1
variants:
-
identifier: language-variant-1
condition: 'siteLanguage("locale") == "de_DE.UTF-8"'
renderingOptions:
enabled: false
properties:
contentElementUid: '49961'
Also siteLanguage(“getTypo3Language”) == “default” or similar did not work.
The only thing that worked was overriding it with Typoscript:
[siteLanguage("languageId") == "1"]
plugin.tx_form.settings {
formDefinitionOverrides {
identifier {
renderables {
0 {
renderables {
0 {
properties {
contentElementUid = 49961
}
}
}
}
}
}
}
}
[global]
So there are two issues:
- Translated element will not be used
- Variant condition on site language doesn’t work
Reviews 3
History 410
-
Josua Vogel changed Duplicates #106901 <span data-processor="relativetime" data-value="2025-07-16T05:31:40+00:00" > 07/16/25, 05:31 </span>
-
Gerrit Code Review pushed patch set 2 for main to change 90080 status
NewUnder Review <span data-processor="relativetime" data-value="2025-07-16T14:14:00+00:00" > 07/16/25, 14:14 </span> -
Gerrit Code Review pushed patch set 1 for 13.4 to change 90088 <span data-processor="relativetime" data-value="2025-07-17T18:09:10+00:00" > 07/17/25, 18:09 </span>
-
Gerrit Code Review pushed patch set 1 for 12.4 to change 90089 <span data-processor="relativetime" data-value="2025-07-17T18:09:22+00:00" > 07/17/25, 18:09 </span>
-
Gerrit Code Review pushed patch set 3 for main to change 90080 <span data-processor="relativetime" data-value="2025-07-17T18:51:14+00:00" > 07/17/25, 18:51 </span>
-
Gerrit Code Review pushed patch set 2 for 12.4 to change 90089 <span data-processor="relativetime" data-value="2025-07-17T18:51:31+00:00" > 07/17/25, 18:51 </span>
-
Gerrit Code Review pushed patch set 2 for 13.4 to change 90088 <span data-processor="relativetime" data-value="2025-07-17T18:51:47+00:00" > 07/17/25, 18:51 </span>
-
Josua Vogel commented and changed status
Under ReviewResolved done0 %100 % <span data-processor="relativetime" data-value="2025-07-18T06:45:12+00:00" > 07/18/25, 06:45 </span>Applied in changeset commit:9eb13eb1a0d6a40c58c3c812a2517b8c15b7e57e.
-
Benni Mack changed status
ResolvedClosed <span data-processor="relativetime" data-value="2025-12-02T14:22:32+00:00" > 12/02/25, 14:22 </span>
This is not just about the not working condition, this is also that if a content element is selected and a translation of the content element TYPO3 should automatically use the element for the current language if exists (no manual condition should be necessary).