filmov
tv
Delete identity user in asp net core
Показать описание
How to delete IdentityUser from the AspNetUsers database table using the identity api.
Healthy diet is very important for both body and mind. We want to inspire you to cook and eat healthy. If you like Aarvi Kitchen recipes, please support by sharing, subscribing and liking.
Text version of the video
Slides
ASP.NET Core Text Articles & Slides
ASP.NET Core Tutorial
Angular, JavaScript, jQuery, Dot Net & SQL Playlists
When the Delete button is clicked, the respective user must be deleted from the AspNetUsers table
Deleting data using a GET request is not recommended.
Just imagine what can happen if there is an image tag in a malicious email as shown below. The moment we open the email, the image tries to load and issues a GET request, which would delete the data.
Also, when search engines index your page, they issue a GET request which would delete the data. In general GET request should be free of any side-effects, meaning it should not change the state on the server. Deletes should always be performed using a POST request.
Deleting data using a POST request
Delete button type is set to submit
It is placed inside the form element and the method attibute is set to post
So when the Delete button is clicked a POST request is issued to DeleteUser() action passing it the ID of the user to delete
Healthy diet is very important for both body and mind. We want to inspire you to cook and eat healthy. If you like Aarvi Kitchen recipes, please support by sharing, subscribing and liking.
Text version of the video
Slides
ASP.NET Core Text Articles & Slides
ASP.NET Core Tutorial
Angular, JavaScript, jQuery, Dot Net & SQL Playlists
When the Delete button is clicked, the respective user must be deleted from the AspNetUsers table
Deleting data using a GET request is not recommended.
Just imagine what can happen if there is an image tag in a malicious email as shown below. The moment we open the email, the image tries to load and issues a GET request, which would delete the data.
Also, when search engines index your page, they issue a GET request which would delete the data. In general GET request should be free of any side-effects, meaning it should not change the state on the server. Deletes should always be performed using a POST request.
Deleting data using a POST request
Delete button type is set to submit
It is placed inside the form element and the method attibute is set to post
So when the Delete button is clicked a POST request is issued to DeleteUser() action passing it the ID of the user to delete
Комментарии