I have a symfony 2.1 application. I followed the tutorial on creating login system from symfony 2.1 documentation. My table structure for user is like this:
users
-id
-username
-email
-password
-last_login_date
What I want to do is update last_login_date for that user when the user logs in. Also update the last_login_date when the user had enabled remember me option.
How can I do this in symfony 2.1 ?
Basically, you need to listen to the security.interactive_login event (you can read more about events here.
Also, check FOSUserBundle, it implements a LastLoginListener which is configured here