Welcome Guest, Not a member yet? Register   Sign In
codeigniter session
#1

[eluser]Unknown[/eluser]
How pass session one controller to another controller.And show username or email when user is logged .
If user logged then user can go session protected page.If not logged then user will redirect to login page .
plz help anyone:question:
#2

[eluser]alvaroeesti[/eluser]


just go directly to the userguide and get exactly the example they give you to work with sessions. Also you will need to set that up in the config file, some encrypted key for that to start working.

next, you just do your query in the model to see if the given username and password correspond to your table values, if yes, redirect to the dashboard. In that dashboard view page, just echo whatever value you want from the array of session values you created before.




Theme © iAndrew 2016 - Forum software by © MyBB