logo       

Re: Correct way to check if user is logged in?: msg#00736

cms.sakai.devel

Subject: Re: Correct way to check if user is logged in?

SessionManager.getCurrentSessionUserId() will be null if the user is not logged in, populated with the user's id if the user is logged in.

- Glenn

Glenn R. Golden
Software Architect, University Of Michigan
ggolden@xxxxxxxxx



On Apr 27, 2006, at 4:48 PM, Zeckoski, Aaron wrote:

What is the right way to check if a user is currently logged in when
viewing a page? The goal is to not let a user view a page if they are
not logged in.

I tried using SessionManager.getCurrentSession() and checking if it is
null but it does not ever seem to be null so this is probably not a good
way to do it.

-AZ

--
Aaron Zeckoski (aaronz@xxxxxx)
Lead Developer - Learning Technologies - Virginia Tech

----------------------
This automatic notification message was sent by Sakai Collab (http://collab.sakaiproject.org/portal) from the DG: Development site.
You can modify how you receive notifications at My Workspace > Preferences.


----------------------
This automatic notification message was sent by Sakai Collab
(http://collab.sakaiproject.org/portal) from the DG: Development site.
You can modify how you receive notifications at My Workspace > Preferences.




<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise