如何实现ASP.Net成员在MVC项目? [英] How to Implement ASP.Net Membership in MVC Project?

查看:114
本文介绍了如何实现ASP.Net成员在MVC项目?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在ASP.NET新会员。我想在ASP.NET MVC项目实现ASP.NET成员资格。我不知道是否有可能或没有。

每当我们打算在那个时候,我们发现改变身份验证(无身份验证,身份认证,组织等)选项来创建MVC应用程序。我有选择的身份认证并获得我的应用程序这些表。 查找连接。

在这里输入的形象描述

不过,我不希望ASP.NET标识表和功能。

我想ASP.NET成员资格表和功能(用户CRUD操作,分配角色,更改用户密码等)的查找连接

在这里输入的形象描述

我已经找到了在SQL Server中创建ASP.NET成员表的方式。


  1. 转到目录C:\\ WINDOWS \\ Microsoft.NET \\框架\\ v4.0.30319点击

  2. aspnet_regsql.exe的。您将看到以下画面。

但你还记得当我们创建一个身份MVC应用程序然后他们提供注册和登录功能,内置的(没有必要写code表示)是的一样,我想在ASP.NET成员资格了。

您答案将AP preciable! :)

在此先感谢:)


解决方案

  

在我ASP.NET成员是新。


您提到的ASP.Net成员超过10岁。微软德precated它。这里是历史 -


  1. ASP.Net Membershi提供商(你提到)

  2. ASP.NET通用提供商

  3. 简单成员资格提供

  4. ASP.NET身份(当前版本是2)

微软向ASP.Net身份动人。这就是为什么你不能找到有关MVC老会员的任何物品。

既然你也是新ASP.Net成员,我个人推荐学习ASP.Net身份。这里是免费的课程和书籍 -

ASP.NET MVC 5基本面由斯科特·艾伦

从亚当·弗里曼的书


  

如何在MVC项目实施ASP.Net会员?


您可以使用的AccountController 按ASP.Net身份产生,并通过自己与会员的UserManager替换。

I am new in ASP.NET Membership. And I want to implement ASP.NET Membership in ASP.NET MVC project. I am not sure is it possible or not.

Whenever we going to create MVC application at that time we found option for change authentication(no authentication, identity authentication, organization etc.). I've select identity authentication and get those tables in my application. look attached.

But I don't want ASP.NET Identity table and functionality.

I want ASP.NET Membership table and functionality(user CRUD operations, assign role, change user password etc) look attached.

I have found the way for create ASP.NET Membership table in SQL Server.

  1. Go to directory C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319 Click
  2. aspnet_regsql.exe. You will see the following screen.

But do you remember whenever we create MVC application with identity then they provide registration and login functionality inbuilt(no need to write code for that) yeah same, I want in ASP.NET Membership too.

Your answer will appreciable! :)

Thanks in advance :)

解决方案

I am new in ASP.NET Membership.

ASP.Net Membership you mentioned is more than 10 years old. Microsoft has deprecated it. Here is the history -

  1. ASP.Net Membershi Provider (you mentioned)
  2. ASP.NET Universal Providers
  3. Simple Membership Provider
  4. ASP.NET Identity (current version is 2)

Microsoft is moving toward ASP.Net Identity. It is why you cannot find any article regarding MVC and old Membership.

Since you are also new to ASP.Net Membership, I personally recommend to learn ASP.Net Identity. Here is the free course and book -

ASP.NET MVC 5 Fundamentals by Scott Allen

ASP.NET identity from Adam Freeman's book

How to Implement ASP.Net Membership in MVC Project?

You can use AccountController generated by ASP.Net Identity, and replace UserManager with Membership by yourself.

这篇关于如何实现ASP.Net成员在MVC项目?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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