Basically, the only changes I made were to the UmbracoMembershipProvider line, and that was to enable password retrieval and require question/answer info.
However, when I call MembershipUser.CreateUser() with a question and answer, the returned MembershipUser does not have a question property.
Does the Umbraco provider not support questions and answers? Does it support password retrieval? Password reset?
Are you sure? From the name (umbracoApprovedPropertyTypeAlias) I'd think that if the underlying Member property was false it wouldn't allow login. But if it were true, it would allow log in.
Probably a stupid question but just to make sure: does this property map with the "MembershipUser.IsApproved" property? Because it keeps returning true in my case, although it is set to false in the Umbraco Membership admin screen (True/False checkbox unchecked).
May have found a bug in there. Been looking at the code for the 4.1 release branch. I've found
config["umbracoApprovePropertyTypeAlias"];
(Missing a 'd' from ApproveD). Can you check whether it works of you're setting membership attribute to umbracoApprovePropertyTypeAlias instead of umbracoApprovedPropertyTypeAlias
MembershipUser: Require Question and Answer, Allow Password Retrieval
I have the membership section of my umbraco site set as follows:
<membership defaultProvider="UmbracoMembershipProvider" userIsOnlineTimeWindow="15">
<providers>
<clear />
<add name="UmbracoMembershipProvider" type="umbraco.providers.members.UmbracoMembershipProvider" enablePasswordRetrieval="true" enablePasswordReset="false" requiresQuestionAndAnswer="true" defaultMemberTypeAlias="WebsiteUser" />
<add name="AspNetSqlMemberShipProvider" type="System.Web.Security.SqlMembershipProvider" connectionStringName="LocalSqlServer" />
<add name="UsersMembershipProvider" type="umbraco.providers.UsersMembershipProvider" enablePasswordRetrieval="false" enablePasswordReset="false" requiresQuestionAndAnswer="false" />
</providers>
</membership>
Basically, the only changes I made were to the UmbracoMembershipProvider line, and that was to enable password retrieval and require question/answer info.
However, when I call MembershipUser.CreateUser() with a question and answer, the returned MembershipUser does not have a question property.
Does the Umbraco provider not support questions and answers? Does it support password retrieval? Password reset?
- Mark
I'd been procrastinating about getting this onto the wiki, but it's done now - our.umbraco.org/.../umbracomembershipprovider-properties
Ohhh....this stuff is good.
Question: If I use umbracoApprovedPropertyTypeAlias will this allow members to login if this is false?
Thanks.
Yes it should, if it doesn't then log that as a bug.
It's coded to work the way you'd expect it to.
Are you sure? From the name (umbracoApprovedPropertyTypeAlias) I'd think that if the underlying Member property was false it wouldn't allow login. But if it were true, it would allow log in.
- Mark
yes that is the applied logic in the code
Probably a stupid question but just to make sure: does this property map with the "MembershipUser.IsApproved" property? Because it keeps returning true in my case, although it is set to false in the Umbraco Membership admin screen (True/False checkbox unchecked).
Thanks.
Michael.
May have found a bug in there. Been looking at the code for the 4.1 release branch. I've found
(Missing a 'd' from ApproveD). Can you check whether it works of you're setting membership attribute to umbracoApprovePropertyTypeAlias instead of umbracoApprovedPropertyTypeAlias
If that works, please report issue on Codeplex.
TIA,
/Dirk
It works indeed with "umbracoApprovePropertyTypeAlias ". Thanks!
Michael.
Sorry Dirk, that's probably just my bad typing, I've fixed the wiki now
is working on a reply...