in my controller i have an public variable i want to use in my view.
public $header = array("show_menu"=>true);
Traditional i would pass variables as an array to the load->view("incl_header",$header)
function, however i have noticed that in my view i can retrieve variables of my controller like so:
echo $this->header['show_menu'];
Are there any problems retrieving variables like this in my view file?
I am using codeigniter 2.1.3