where("id", $id)->find(); if (empty($item->id)) { return Kohana::show_404(); } $this->template->set_global('item', $item); $this->template->set_global('children', $item->get_children()); $this->template->set_global('theme', new Theme("default", $this->template)); } }