i working on asp.net c# webforms project. want redirect login.aspx page when session expires. have javascript based solutions available on internet work fine. work off of global.asax page code in 1 place. tried redirect session_end event on global.asax didn't work no response , request object available event. there references use application_acquirerequeststate event in redirecting page on session_end event didn't work either. appreciated.
thanks
it's been while since i've lived in .net world, far recall, session_end
fires on server without request triggering it. in other words, when session expires, session_end
fire. won't have request @ point in time.
also, if ever need move external sessions, session_end
won't fire:
so, may not want rely on session_end
in first place.
since don't have request, can't redirect server. have in javascript. if really need server "push" redirect connected clients, use websockets accomplish this. (i think bad idea, though.)
Comments
Post a Comment