开发者

How can I redirect the user to the same page he was before when he logs in?

开发者 https://www.devze.com 2022-12-30 04:55 出处:网络
I\'m going to add my own user control LoginBox to my MasterPage. I want to just refresh the page the user is currently on when he logs in to the system开发者_JS百科. How can I accomplish this?Store t

I'm going to add my own user control LoginBox to my MasterPage.

I want to just refresh the page the user is currently on when he logs in to the system开发者_JS百科. How can I accomplish this?


Store the landing page in a session variable, then when the user logs in use that for where to redirect them.


Better use this:

Request.UrlReferrer.AbsoluteUri

this will more or less solve your problem.

0

精彩评论

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