https://www.icyphoenix.com/viewtopic.php?f=35&t=8875&p=57935#p57935
-----------------------------------
AndyGpy
Fri 04 Jan, 2013 10:22

How Do I Check If A User Is Logged In ?
-----------------------------------
I have moved to ICY 2.0, i have a seperate page that i use which is no longer working.

It checks if a user is logged in, if so then it pulls information from a database, it was fully working in 1.53, i noticed that the session management has changed so my question to you experts is

what is ICY2.0 equivalent to this ICY1.53 code

[code linenumbers=false]// standard session management
$userdata = session_pagestart($user_ip);
// Check to see if user is logged in  

if ((!$userdata['session_logged_in']) ) 
	// No he isnt
   {
        redirect(append_sid(LOGIN_MG . '?redirect=alerts.' . PHP_EXT));
	
   }

else
	// Yes they are
   {
		init_userprefs($userdata);

                rest of my code 
                .
                .


   }

an how do i parse into a tpl called alertz_VIP.tpl or is the method of parsing still the same ?

regards


