开发者

ASP.NET How to dynamically change session time for current logged user?

I'm wondering if it is possible to change dy开发者_C百科namically the session time for currently logged user. I'm communicating with a WebService which does a long-running task, and while the it sends the final response, I don't want the user to be logged out. Is it possible ?


One technique involves continuously pinging the application at regular intervals using AJAX or some dummy image fetching which will renew the session cookie.


Show a processing page and have it auto refresh at appropriate intervals of time. You want to do this anyway, as you can't have the browser waiting for such a long running operation.

Above said, why do you need for the user to still be logged? Is this happening client side instead? If it is done server side you should structure the code so it isn't affected by the session like that.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜