
[英]How to perform an automatic login after confirming the account with ASP.NET Identity
[英]ASP.NET Redirects to Login After Automatic Account Creation…Why?
我有一个带有CreateUserWizard控件的create_account.aspx页。 它的LoginCreatedUser属性设置为true。
创建帐户并在CreateUserWizard_CreatedUser中进行一些进一步的连接后,请执行以下操作:
Response.Redirect("~/dashboard/default.aspx")
然后将个人重定向到login.aspx页面,就好像他们未通过身份验证一样? 为什么?
我怀疑它可能与以下事实有关:default.aspx位于我有一个web.config文件的子目录中,
<configuration>
<system.web>
<authorization>
<deny users="?"/>
</authorization>
</system.web>
</configuration>
有什么想法吗?
您可能想要尝试将CreateUserWizard ContinueDestinationPageUrl属性设置为所需的URL,即。 ContinueDestinationPageUrl="~/dashboard/default.aspx"
。 也可以编程方式完成。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.