Welcome Guest, Not a member yet? Register   Sign In
Layout Engine
#2

[eluser]jedd[/eluser]
Hi Heliton,

Quote:Also I wanna ask if I really have to load views for every controller function.

You could load your header & footer views into variables, in the constructor of your Blag class - and then just echo them out in your final view.

Alternatively you can extrapolate that approach up another level by extending the core controller (lookup MY_Controller in the user guide).

I've rambled about this at some length [url="http://codeigniter.com/wiki/Header_and_Footer_and_Menu_on_every_page_-_jedd/"]in the wiki[/url].


Messages In This Thread
Layout Engine - by El Forum - 09-05-2009, 09:44 AM
Layout Engine - by El Forum - 09-05-2009, 10:00 AM
Layout Engine - by El Forum - 09-08-2009, 09:38 PM
Layout Engine - by El Forum - 09-09-2009, 01:18 AM



Theme © iAndrew 2016 - Forum software by © MyBB