Actions
Bug #60135
closedNested stdWraps cause multiple "function calls"
Status:
Closed
Priority:
Must have
Assignee:
Category:
TypoScript
Target version:
Start date:
2014-07-07
Due date:
% Done:
100%
Estimated time:
TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
easy
Is Regression:
No
Sprint Focus:
Description
In case of nested stdWraps, the specified objects (like TEXT or USER) will be called multiple times even though the output is still only being rendered once. This sucks especially for userfuncs and REGISTER (the "famous" counter scenario).
page = PAGE page { 10 = TEXT 10.value = page.10.value<br> 10.append = TEXT 10.append.value = page.10.append.value<br> 10.stdWrap.append = TEXT 10.stdWrap.append.value = page.10.stdWrap.append.value<br> }
The output in the browser is as expected:
page.10.value page.10.stdWrap.append.value page.10.append.value
If you now modify the TEXT class (typo3/sysext/frontend/Classes/ContentObject/TextContentObject.php) and prepend the following to render():
var_dump($conf['value']);
you'll see that this object is acutally being called not 3 but 4 times! I guess it's also possible to track this behaviour with the admin panel.
Anyway, to render "page.10.stdWrap.append.value" its TEXT object is being called two times, which is one time too much, imho. If you wrap it within another stdWrap, it's even called 4 times.
Actions