Start a new topic
Solved

VC1.8: User Registration for a "Restricted Access" Store didn´t work

Did someone experience the same problem?


Are there any solutions/fixes available?


In this case the logon view is re-loaded instead loading the register view.


Regards

Carlo


This issue was solved in version 1.9

 

 That is a bug in StoreHttpModule:

protected virtual void RedirectToLogin(HttpContext context)
{
if (!context.Request.Url.AbsolutePath.Equals(FormsAuthentication.LoginUrl, StringComparison.InvariantCultureIgnoreCase) &&
!context.Request.Url.AbsolutePath.Equals(VirtualPathUtility.ToAbsolute("~/Account/Register"), StringComparison.InvariantCultureIgnoreCase))
{
context.Response.Redirect(FormsAuthentication.LoginUrl + context.Request.Url.Query);
}
}


The bold text is incorrect should be changed to:

protected virtual void RedirectToLogin(HttpContext context)
{
if (!context.Request.Url.AbsolutePath.Equals(FormsAuthentication.LoginUrl, StringComparison.InvariantCultureIgnoreCase) &&
!context.Request.Url.AbsolutePath.EndsWith("/Account/Register", StringComparison.InvariantCultureIgnoreCase))
{
context.Response.Redirect(FormsAuthentication.LoginUrl + context.Request.Url.Query);
}
}


This will be fixed in new release.


Also remember that if you register to restricted store you cannot login until admin gives you Private Shopper role.

Login or Signup to post a comment