Reputation: 89
I have a page in asp.net. A button click in the page will open a pop-up.
Now if session is expired, it is opening the pop-up window and in the pop-up it is showing the login screen.
Is there any way in which i can avoid pop-up being opened if the session is expired and directly go back to login page?
Upvotes: 1
Views: 463
Reputation: 1
I am not sure I understand your requirement clearly. There is no exact way to achive this. But we can do it javascript.
put a timer(duration would be session timeout, use settimeout function) in the parent page. Check this value before open a popup.
Upvotes: 0
Reputation: 21137
When you say pop-up, do you mean window.open? If so, then you have to make a AJAX call to verify the session, before opening the new window.
Upvotes: 1