Is this forum also for codeigniter questions or just straight PHP ( no framework )?

I guess u are allows to ask anything related to PHP, frameworks or not.

yeah, I just don’t recall many CI questions…


I am using a default layout, then nesting the view I need for a particular page. A stripped down simple example:

 <!DOCTYPE html>

        <div id="mainContent" class="pure-u">

Where $viewToLoad will be the name of the nested view to load.

My issue is I have navigation in the default layout that is the same for every page of the site. The nav items are queried from a db.

So I thought since the nav data will be the same for every page on the site, that I should gather the data in CI_Controller…correct?

But right now the issue is calling this: $this->load->model(“Model”); from inside CI_Controller doesn’t find the model, so I can’t get the data.

If this is the correct approach, how do I get data returned to CI_Controller?