Loading views within the error template - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Loading views within the error template (/showthread.php?tid=15901) |
Loading views within the error template - El Forum - 02-18-2009 [eluser]Unknown[/eluser] Hey, I am completely new to CI and am just experimenting with it at the moment. It looks brilliant so far. I am however trying to make the 404 Error template fit in with the rest of my application. To achieve this, I have created two views called "tpl_header.php" and "tpl_footer.php" which are included within all the other views. This doesn't seem to be possible within the error template however as it isn't a normal "view". Is there any way I can include the template files? Regards, Dan Loading views within the error template - El Forum - 02-18-2009 [eluser]TheFuzzy0ne[/eluser] Can't be done. The error page has to also work in the event that CodeIgniter itself is not working. It's not loaded or parsed as a view, and therefore CodeIgniter is inaccessible. I have created a static header which is the same as the dynamic one, but stripped of all variables. Granted, some data is missing, but the error page looks like it's a part of the Web site, and users can use the top navigation to navigate elsewhere, such as the Contact Us form to complain... Loading views within the error template - El Forum - 02-18-2009 [eluser]TheFuzzy0ne[/eluser] Oh, and welcome to the CodeIgniter community!! (Sorry, got distracted). Loading views within the error template - El Forum - 02-18-2009 [eluser]Unknown[/eluser] ok i'll get to work doing that then. thanks for the quick reply! |