[eluser]Unknown[/eluser]
Hello there, greetings from Brazil and 10x for the good work. Sorry the bad english, here we go:
I had a standard header and footer for my website, so all the views go like this:
<?=$this->load->view("header");?>
Html text and generated text of the view
<?=$this->load->view("footer");?>
Fine. But after finished the website (always on this part), the client requested a modification and now I've a news ticker on the footer.
Doubt: how am I supposed to get db data directly from a view? 'couse otherwise I would have to change all my controllers (is, they are too much) to first get the news info and send it into the views
I tried to get a pre_controller hook to store the news info into a session var, but the hook doesn't connect to the database. I guess it is not loaded yet.
So, that's it.