Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / December 2007

Tip: Looking for answers? Try searching our database.

Is it possible to use the email instead of username?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Alexis - 13 Dec 2007 03:31 GMT
Is it possible to use the email instead of username in the login control.?

I'm using ASP.NET membership functionality.
I'd rather have each user account keyed on an
email instead of a user name. My main problem with user names is that
duplicates become likely and I don't want people to have to enter a bunch of
different user names before a unique one is found.
Mark Fitzpatrick - 13 Dec 2007 03:48 GMT
There's nothing to prevent you from asking them to use their email address
as a username. Simply use a regular expression validator when they create
their account to ensure they are entering a valid email. You'll probably
want to hand-code the account creation process and set the username and
email to the value they enter.

Signature

Hope this helps,
Mark Fitzpatrick
Microsoft MVP - Expression

> Is it possible to use the email instead of username in the login control.?
>
[quoted text clipped - 4 lines]
> of
> different user names before a unique one is found.
Michael Nemtsev - 13 Dec 2007 04:03 GMT
I found using the email as userID more intuitive.

and then u can provide the First/Second name to display user name, without
showing user email

Signature

WBR,  Michael  Nemtsev [.NET/C# MVP].  
Blog: http://spaces.live.com/laflour

> Is it possible to use the email instead of username in the login control.?
>
[quoted text clipped - 3 lines]
> duplicates become likely and I don't want people to have to enter a bunch of
> different user names before a unique one is found.
Eliyahu Goldin - 13 Dec 2007 08:55 GMT
You can make use of the Membership.GetUserNameByEmail method to get the user
name and authenticate it programmatically.

Signature

Eliyahu Goldin,
Software Developer
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net

> Is it possible to use the email instead of username in the login control.?
>
[quoted text clipped - 4 lines]
> of
> different user names before a unique one is found.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.