Foros de discusión

How to obtain the very first request from user in Liferay?

thumbnail
Vitaliy Koshelenko, modificado hace 11 años.

How to obtain the very first request from user in Liferay?

Expert Mensajes: 319 Fecha de incorporación: 25/03/11 Mensajes recientes
Hi, all.

Does anybody know how to obtain the first request from user in Liferay?
I need something like a filter, not for all user requests, but only for the very first request. (I need to perform some custom actions - retrieving IP from request, etc.)
Please, give me some advice how to implement this.

Regards, Vitaliy.
thumbnail
David H Nebinger, modificado hace 11 años.

RE: How to obtain the very first request from user in Liferay?

Liferay Legend Mensajes: 14919 Fecha de incorporación: 2/09/06 Mensajes recientes
Why not a LoginPostAction implementation?
thumbnail
Vitaliy Koshelenko, modificado hace 11 años.

RE: How to obtain the very first request from user in Liferay?

Expert Mensajes: 319 Fecha de incorporación: 25/03/11 Mensajes recientes
As I understand, LoginPostAction will be invoked after user had logged into portal, but I need to intercept the first request, when user accesses the portal page first time (at this moment he is Guest), not after logging in.
thumbnail
David H Nebinger, modificado hace 11 años.

RE: How to obtain the very first request from user in Liferay?

Liferay Legend Mensajes: 14919 Fecha de incorporación: 2/09/06 Mensajes recientes
Then I'd do a filter. You can place a value in the session to determine if the user has been there before, and absence of the value means they're new and you can do what you want to.

To do a filter, you'll have to use the ext plugin.