Bug #104576
closedDisabled sys_template records are included via basedOn
0%
Description
When you include a disabled TypoScript template via the basedOn
field, the TypoScript record is loaded and effective on the website.
In TYPO3 v11 it worked as expected (disabled record is not effective), upgrading to v12 we experience this issue.
Files
Updated by Garvin Hicking 3 months ago
- Status changed from New to Needs Feedback
Some findings, also shared on slack where this was reported in #typo3-cms:
That's odd. vendor/typo3/cms-core/Classes/TypoScript/IncludeTree/SysTemplateTreeBuilder.php
in method getBasedOnSysTemplateRowsFromDatabase
calls:
$queryBuilder->setRestrictions($this->getSysTemplateQueryRestrictionContainer());
and that uses:
$restrictionContainer = GeneralUtility::makeInstance(DefaultRestrictionContainer::class); if ($this->context->getPropertyFromAspect('visibility', 'includeHiddenContent', false)) { $restrictionContainer->removeByType(HiddenRestriction::class); }
so theoretically it should include the basedOn records only if the context property includeHiddenContent is enabled. Any chance you set that somewhere?
Or do you maybe use the frontend admin simulator toolbar and have that property enabled?
Updated by Christian Kuhn 3 months ago
- Related to Feature #97816: New TypoScript parser added
Updated by Sebastian Michaelsen 1 day ago
- Status changed from Needs Feedback to Closed
We have finally gotten to the bottom of this and it's not a TYPO3 core issue. What we did was, we disabled TypoScript records in an Update script, using DataHandler and forgot to add the cache clearing in the script. So the TypoScript record was disabled in the backend, but effective in the frontend - until the frontend cache was cleared.
Updated by Garvin Hicking about 15 hours ago
Thanks for getting back to it and adding feedback, this is much appreciated :)