Subject: Foreach statement never loops
Date: 2010-09-27 15:18:07
From: John Wollner
Source: foreach-statement-never-loops

Iam trying to evaluate your product but having a problem.  I have a list of objects (List<Person>) that I'm trying to iterate in a foreach loop in a template, such that I get one set of output for each person all in one file.

It appears that the following statement:   {%foreach per in Prospects%}  although it performs the enclosed templating as many times as there are elements, the current element is always the first one.  It never advances through the loop.

Should it not process each element in the list?
---------------------------------------------------------------------- Note: This question has been asked on the Q&A forum of Thang Dang's fraudulent ComponentPro brand If you purchased anything from ComponentPro, you have been scammed. Contact the payment processor who sold you the license and ask for your money back. Back to ComponentPro Q&A Forum Index