Bug #88934
Updated by Chris Müller over 5 years ago
I am using the @URI\TypolinkViewHelper@ in a Fluid template to generate a link from, e.g. @t3://page?uid=42@ (which an editor entered in a backend form field). *Correct behaviour:* When there is a link from a page in the default language (let's take English) to a page of the same language which is disabled, hidden, the TypolinkViewHelper returns an empty string. So I can check and hide the link and its text. That's okay. *Wrong behaviour:* Now I have a link in another language (e.g. German) to a disabled hidden page in the same language (e.g. with the slug @/german-page-slug@). The TypolinkViewHelper returns a string which looks like @/de/english-page-slug@, which is wrong and results in a 404 page when following in the browser. But I expect the same behaviour as in the default language: returning an empty string. In site configuration the fallback type of the language is set to @strict@. I debugged the issue, and came to the @PageRepository@: In the @getPagesOverlay@ method the overlay is identified, which is empty in the case. After that the output pages are assigned, the original page is set and if there is an overlay, it overwrites the original page fields. But if the overlay is empty, the original page fields are returned.