Liferay If user is already login and he manually enters login page url? -



Liferay If user is already login and he manually enters login page url? -

i need if user login , manually enters login path redirects home page?.please allow me know how how perform this.

thanks

as far understand want after login if come in next sign-in url:

http://localhost:8080/web/guest/home?p_p_id=58&p_p_lifecycle=0&p_p_state=maximized&p_p_mode=view&savelastpath=0&_58_struts_action=%2flogin%2flogin

then should taken home page i.e. http://localhost:8080/web/guest/home.

so if case think can create servlet-filter hook intercept requests , check relevant parameters of url such struts_action=/login/login , next (in psuedo code):

if(is_signin_url) { // check if sign-in url if(isuserloggedin) { // check if user logged-in // redirect home page configured in portal-ext.properties } else { // allow application work i.e. allow go sign-in page } }

also info , in-depth understand can check lifeary's autologinfilter class (this actual servlet-filter can create hook along same lines) , liferay-web.xml url c/portal/login takes home page if user logged-in or else takes sign-in page.

and independent of using cookie :-)

liferay

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -