是否有可能与会员API更改用户名 [英] Is it possible to change the username with the Membership API

查看:201
本文介绍了是否有可能与会员API更改用户名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用与ASP.NET默认的SQL成员资格提供程序,我想提供一个页面来改变用户的用户名。我相信,我相信,我可以用一个自定义的供应商做到这一点,但是这可以使用默认的供应商来完成?

I am using the default sql membership provider with ASP.NET and I would like to provide a page to change the user's username. I believe I am sure I could do this with a custom provider, but can this be done with the default provider?

我的问题的第二部分是:
我是否应该允许创建帐户后用户更改他们的用户名?

Second part of my question is: Should I allow users to change their username after the account is created?

推荐答案

这是真的,默认SQL成员资格提供程序不允许用户名的变化。然而,有没有内在的理由prevent用户更改他们的用户名,如果你有一个有效的说法,您的网站,允许它。在SQL数据库具有的用户名作为密钥表的无,一切是基于该用户的ID,因此从实现的角度来看这将是相当容易的。

It's true that the default SQL Membership Provider does not allow username changes. However, there's no intrinsic reason to prevent users from changing their usernames if you have a valid argument, on your site, to allow it. None of the tables in the SQL database have the username as a key, everything is based on the user's ID, so from an implementation perspective it would be fairly easy.

这篇关于是否有可能与会员API更改用户名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆