Project

General

Profile

Actions

Bug #104576

closed

Disabled sys_template records are included via basedOn

Added by Sebastian Michaelsen 3 months ago. Updated about 15 hours ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
TypoScript
Target version:
-
Start date:
2024-08-09
Due date:
% Done:

0%

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

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

Screenshot_2024-08-09_at_08_02_16.png (112 KB) Screenshot_2024-08-09_at_08_02_16.png Sebastian Michaelsen, 2024-08-09 06:12

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Feature #97816: New TypoScript parserClosed2022-06-27

Actions
Actions #1

Updated by Garvin Hicking 3 months ago

  • Category set to TypoScript
Actions #2

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?

Actions #3

Updated by Christian Kuhn 3 months ago

Actions #4

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.

Actions #5

Updated by Garvin Hicking about 15 hours ago

Thanks for getting back to it and adding feedback, this is much appreciated :)

Actions

Also available in: Atom PDF