Ismail
Ismail

Reputation: 31

.Net Core 3.1 MVC Authentication Individual User Accounts and Scaffold Identity in ASP.NET Core projects

Following this guide:

Introduction to Identity on ASP.NET Core

https://learn.microsoft.com/en-us/aspnet/core/security/authentication/identity?view=aspnetcore-3.1&tabs=visual-studio

Scaffold Identity in ASP.NET Core projects

https://learn.microsoft.com/en-us/aspnet/core/security/authentication/scaffold-identity?view=aspnetcore-3.1&tabs=visual-studio

If I run the app, and click on the "Register" link from the navbar, it redirects to: https://localhost:44397/Identity/Account/Register but if I try to create a new account and register

I get This page isn’t working If the problem continues, contact the site owner. HTTP ERROR 400 The same applies to the Login page

Upvotes: 0

Views: 2946

Answers (1)

Yinqiu
Yinqiu

Reputation: 7180

Usually,the simplest steps to create a scaffolding project are as follows.

1:Create a new project then change the Authentication: enter image description here

2:Click the project Add and then click New Scaffolded Item. enter image description here

3:Chooes Identity then add: enter image description here

4:Override all files and choose the context as ApplicationDbContext then add enter image description here

5:Migration and run project.Register first and then log in

Upvotes: 2

Related Questions