I'm currently using Latte to do things.
What I can't figure out is how to use a foreach loop on a query with it's template variables. My code below would always return in Trying to get property of non-object
$query = $this->db->query("SELECT id FROM table");
$array = array();
while($fetch = $query->fetch_array()){
$array = $fetch;
}
$Template["qclisting"] = $array;
And the template code
{foreach $qclisting as $item}
<a href="" class="list-group-item clearfix">
<span class="clear">
<span>{$item->id}</span>
</span>
</a>
{/foreach}