简体   繁体   中英

Sitecore api that returns sign in page?

Anybody knows the Sitecore api method that returns the sign in url as below?

 https://dev.site/signin?item=%2fmyaccount&user=extranet\Anonymous&site=website

The above url is rendered when the user clicks on my account link before logging in.

If the method is already available in sitecore api, I would rather use it instead of writing my own.

Thanks

You can use:

Sitecore.Web.WebUtil.RedirectToLoginPage(context);

That will redirect to the Sitecore login page. context is the HttpContext of your request.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM