Welcome Guest, Not a member yet? Register   Sign In
loading a view and stopping any other view loads
#1

[eluser]AtlantixMedia[/eluser]
Hello,

I basically have a setup where I'm extending the controllers class to do some routine checks before getting to the requested controller class->function. if a certain check fails, I want to be able to load a view (a splash page) without doing any further script execution, sort of an exit;

now the problem is that if I issue an exit; the view is not loaded. if I don't issue an exit;, the splash page is not loaded as another view gets loaded further in the script.

how can I go about this? the closes example I can give is that of a website which has restricted content you can view only if you go through an enter/leave page.

thanks
#2

[eluser]Rick Jolly[/eluser]
Maybe try this:
Code:
ob_start();
$this->load->view('splash');
ob_end_flush();
exit();
#3

[eluser]AtlantixMedia[/eluser]
thank you very much. that has solved the problem. thanks!!




Theme © iAndrew 2016 - Forum software by © MyBB