Welcome Guest, Not a member yet? Register   Sign In
How To Use Javascript In CI??
#1

[eluser]indigoblue[/eluser]
I want to add javascript alert code like this :
Code:
[removed]
alert("You Dont not Have Permission To Access This Area");
alert("Please Loggin Before...");
[removed]

In a function of my class controller :
Code:
function is_logged_in(){
            $is_logged_in= $this->session->userdata('is_logged_in');
            if (!isset($is_logged_in) || $is_logged_in!=true ){
            /*
                        I wanna place javascript code in this area
                        */
                        redirect('/home/');
            }
        }

But, the problem is that script aren't working??
Thx b4...


Messages In This Thread
How To Use Javascript In CI?? - by El Forum - 12-05-2010, 03:12 AM
How To Use Javascript In CI?? - by El Forum - 12-05-2010, 07:03 AM
How To Use Javascript In CI?? - by El Forum - 12-06-2010, 07:01 PM



Theme © iAndrew 2016 - Forum software by © MyBB