tags:

views:

45

answers:

2

Hello all,

Being quite new to liferay/portal/portlet development you run into problems daily . Now i'm trying to for a logout from a portlet but have not found a way to accomplish that. How are you supposed to do that? Should I try to send some kind of logout event or something? Greping around in the liferay sources i have found a LogoutAction.java that seems promising but how do one trigger that?

Best Regards Anders Olme

+1  A: 

PortletSession.invalidate() ?

binary_runner
That just invalidates the portlet but the other portlets are still up and running and the portal user is still logged in.
Buzzzz
Guess a more correct title would have been to trigger a portal logout.
Buzzzz
I've found that there is LogoutAction mapped to /portal/logout, so redirecting there or providing link could work. I've not tried it yet.
binary_runner
A: 

try actionResponse.sendRedirect("/c/portal/logout")

dtruong