How to extend aspnet membership forms authentication tables?

前端 未结 2 1953
一整个雨季
一整个雨季 2021-01-05 10:54

I would like to add a realName field in addition to the user\'s user name and email address.

In the past I have created a new table that includes the <

相关标签:
2条回答
  • 2021-01-05 11:22

    You should use the Membership User Profile API to extend custom properties to your users, and not directly add columns to the aspnet_Membership and aspnet_Users tables.

    You can also look at the SqlTableProfileProvider

    And make sure you read Joel's and Colivier's posts here on how to create strongly typed profile classes.

    0 讨论(0)
  • 2021-01-05 11:37

    If this is a Web Application project you will need to use a custom profile class as Profiles only come out of the box with the Website model:

    http://www.codersbarn.com/post/2008/07/10/ASPNET-PayPal-Subscriptions-IPN.aspx

    http://weblogs.asp.net/joewrobel/archive/2008/02/03/web-profile-builder-for-web-application-projects.aspx

    0 讨论(0)
提交回复
热议问题