Here’s a completely pointless blog to test my newly installed code highlighting plugin…
function categories() { $category = new Category(); $category->order_by('name', 'asc')->get(); $results = array(); $x = 0; foreach ($category as $c) { $results[$x]['id'] = $c->id; $results[$x]['name'] = $c->name; $x++; } $this->output->set_output(json_encode($results)); Iphone_activity::add('categories'); }
Cool, huh?