Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

for cicle problem


Reply


608 Views

Avatar
bebabeba

Community Member, 193 Posts

24 November 2008 at 11:13pm

Hi!
I have a query that look for in my database and show me 35 results. I want print this result in my page inside a div. My problem is create a for cicle that include div and result of query. can you help me please?How silverstripe convert this:

$array [] //this is the array that include all query result

for($i=0;$i<count($array); $i++){
<div>
print_r($array($i))
</div>
}