function _load_view($view) { //header part $header = View::factory('common/header', array('member_id'=>$this->member_id, 'member_name'=>$this->member_name, 'division_name'=>$this->division_name) ); //template - main $template = View::factory('template', array('content'=>$view) ); $template->header = $header; $this->response->body = $template; }
echo $header; echo $content; echo View::factory('common/footer');
$this->load->view('header); $this->load->view('content');
$this->load->view('template', array( 'var' => 'foo' )); //$var is available in both header and content.Any idea?
Thank you so much.Jelmer Schreuder wrote on Friday 6th of May 2011:View docs, look for the View::set_global() method.
It looks like you're new here. If you want to get involved, click one of these buttons!