#36820FLUIDTEMPLATE - Serialization of 'Closure' is not allowed
Description
A tricky one that was reported for the YAG extension as well.
What you need:
- FLUIDTEMPLATE
- COA_INT or USER_INT
Example:
page.20 = FLUIDTEMPLATE
page.20 {
file = fileadmin/fluid.html
partialRootPath = fileadmin/Partials/
}
page.30 = COA_INT
page.30.10 = TEXT
page.30.10.value = TEST
Contents of the Fluid Template file (fileadmin/fluid.html):
<f:render partial="Test" />
Contents of the Test partial (fileadmin/Partials/Test.html):
HELLO WORLD
Now, call the page (to have it cached) and then call another page that uses that cache – you should see a nice error/exception for handling the COA_INT.
Explanation:- The Partial handling in the RenderViewHelper will store a compiled version, using Closure in the cache
- Thus, the first call works, but the second one, using the cache will use the Closure
- The serialize($this->cObj) in COA_INT will stumble over the Closure deep down in cObj and fail
Closures have been introduced in Fluid with TYPO3 4.6.
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.