velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ed Yu" <e...@asgnet.psc.sc.edu>
Subject Question about #foreach
Date Sun, 14 Jul 2002 14:38:10 GMT
I've got a question about the #foreach directive. When reading the docs,
it mentioned about the index variable velocityCount within the
directive. My question is what is the name of the variable if there is a
nested #foreach construct:

#foreach ($objList in $objLists)
	#foreach ($obj in $objList)
	#end
#end

How do I access the outer loop variable other than setting it explicitly
like:

#foreach ($objList in $objLists)
	#set ($outerIndex = $velocityCount)
	#foreach ($obj in $objList)
	#end
#end


--
To unsubscribe, e-mail:   <mailto:velocity-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:velocity-user-help@jakarta.apache.org>


Mime
View raw message