In my project, many web pages are there and each one having own URL like
localhost:8080/MyProject/login
localhost:8080/MyProject/logout
localhost:8080/MyProject/denied
localhost:8080/MyProject/home
when my project run showing as localhost:8080/MyProject/login
. when shows this type of url in browser tab I don't want any method calling. when tab or browser closing wants to call a custom method using spring can any one help me how to call a method when tab or browser closing.