[eluser]nelson.wells[/eluser]
You could write a custom controller that inherits from the base controller, load the variables in that controller's constructor, and then have all of your other controllers inherit from
that constructor. Something like this (written in the browser, so untested.):
Code:
class MY_Controller extends CI_Controller
{
function __construct()
{
//global variables
$data["my_header_view_DATA"] = "Tralala";
$data["my_right_column_view_DATA"] = "-->Something that i'm bringing from my database<--";
$this->load->vars($data);
}
}
Code:
class Welcome extends MY_Controller
{
//your normal controller methods
}
Any controller that extends MY_Controller will have access to $my_header_view_DATA in the view it loads. Like I said, it is untested so it may have typos, but the idea is there. Hope that helps.