Question

Im in the middle of creating a MVC 4 web site and need to make use of some sort of membership provider. I have been following some tutorials about custom membership providers, but I have also been reading about just using the default one... And now Im just more confused than before I started :) When is it a better solution to use the default membership provider rather than making your own? When I look at my MyCustomMembershipProvider.cs class, I see a lot of methods that overrides the ones from MembershipProvider.cs. Almost all the methods is something I need in my web site, so in the end I will just be creating a copy of the default membership provider..??

Was it helpful?

Solution

Unless you're one of those people that hates the way the default membership is implemented, or you have very specific needs for a membership provider, then there is no reason to avoid using the default provider. In other words, if you really don't care how it works, just use the default.

In particular, though.. MVC 4 uses the Simple Membership Provider by default, which is different from the SqlMembershipProvider (usually considered the default in most tutorials you'll read). You'll want to read up on how the Simple Membership Provider in MVC4 works.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top