[TYPO3-mvc] having a few problems nesting inline viewhelpers
Christian Kuhn
lolli at schwarzbu.ch
Mon Mar 19 20:11:50 CET 2012
Hey again.
On 03/19/2012 07:42 PM, Christian Kuhn wrote:
> On 03/19/2012 07:37 PM, Stephen Bungert wrote:
>> <f:for each="{sbp2:sortTitle(records: {sbp2:combineTags(record:
>> item)})}" as="tag" iteration="tagInfo">
>>
>> It causes the following error:
>>
>> #1237900529: The argument "each" was registered with type "array", but
>> is of type "string" in view helper "Tx_Fluid_ViewHelpers_ForViewHelper"
Rules are actually pretty simple:
- Only ticks (') must be quoted with a single backslash, if surrounded
by a higher level tick of the outer viewhelper
- Ticks within a quoted tick must be quoted, the number of backslashes
is n*2 + 1, with n the number of backslashes of the previous quotation
So, number of backslashes is: 1,3,7,15,...
Hint: From 3 backslashes it gets really ugly and you might want to solve
your problem differently ;)
Code for reference:
<f:translate
key="logForNonPageRelatedActionsOrRootLevelOrPage"
arguments="{
0: '{f:translate(
key:\'forPage\',
htmlEscape:\'0\',
arguments:\'{
0:\\\'{belog:be.pagePath(pid:\\\\\\\'{pid}\\\\\\\')}\\\',
1:\\\'{pid}\\\'
}\'
)}',
1: '{f:format.date(format:\'{settings.dateFormat} H:i\',
date:\'@{constraint.startTimestamp}\')}',
2: '{f:format.date(format:\'{settings.dateFormat} H:i\',
date:\'@{constraint.endTimestamp}\')}'
}"
/>
HTH
Christian
More information about the TYPO3-project-typo3v4mvc
mailing list