[TYPO3-mvc] Fluid - is there a way to check if an object is the first or last object?

Sebastian Kurfürst sebastian at typo3.org
Tue Jul 27 08:35:36 CEST 2010


Hey,

> I don't see any downside of this, because "as" will always be unique in
> the template, as well as will be the iteration array using the "as"
> label as default prefix.
we don't want to register additional variables intransparently to the
user; as it is not possible to re-declare/override a variable in the
Template. So, if the user has created a "fooIteration" before the
<f:for> loop (for whatever reason), he will get a very strange error
message telling him that the "fooIteration" variable should not be
overriden -- however, in his code, he only sees "fooIteration" once.

That's why we decided to keep it simple, and will explicitely specify
such variables. It is a little more verbose, but IMHO easier to read and
understandable.

Greets,
Sebastian


More information about the TYPO3-project-typo3v4mvc mailing list