[eluser]theprodigy[/eluser]
Quote:Code:
class About_model extends CI_Model {
function getAll() {
$q = $this->db->get('abouts');
if($q->num_rows() > 0){
foreach ($q->result() as $row)
{
$data[] = $row;
}
return $data;
}
}
}
Try changing your getAll function to
Code:
class About_model extends CI_Model {
function getAll() {
$q = $this->db->get('abouts');
$data = array();
if($q->num_rows() > 0){
foreach ($q->result() as $row)
{
$data[] = $row;
}
}
return $data;
}
}
After making that change, try running print_r on it again and see what happens.