I have the following in my codeigniter constructor:
$navbar= new stdClass();
$navbar->user_email = $this->user_email;
$navbar->vp = $this->vp;
When I try to access this in my index function:
public function index() {
var_dump($this->navbar);
this works.
I now tried to pass $this->navbar to the view with:
$this->load->view('buyers/navbar', $this->navbardata);
In the view I have
<?php echo 'in nav ';var_dump($this->navbar); exit; ?>
I get :
Message: Undefined property: MY_Loader::$navbar
How can I make this work?
Thanks in advance,