Reputation: 245
I have an asp.net site where I am using a XML based Tiny Membership provider. I want to send an email on email address provided by user while he creates an account on my site, which will have link. Its only after clicking on this link I want his account to get activated. How can incorporate this functionality in existing default behavior of Membership Provider?
Upvotes: 0
Views: 288
Reputation: 124746
When you create the user, set MembershipUser.IsApproved
to false, and send an email with the link to the new user. The Membership.CreateUser
method has a parameter isApproved
for this purpose.
When the user clicks on the link, validate then set MembershipUser.IsApproved
to true.
Upvotes: 3