ASP.Net - MVC C#| Error: The required anti-forgery form field "__RequestVerificationToken" is not present.

 

ASP.Net - MVC C#| Error: The required anti-forgery form field "__RequestVerificationToken" is not present.

I am using Membership.create user function, then the following error is occurring,
 
The required anti-forgery form field "__RequestVerificationToken" is not present.

How can I fix this?

Solution: 

 You have [ValidateAntiForgeryToken] attribute before your action. You also should add @Html.AntiForgeryToken() in your form.

 

Enjoy !!!

:) 

No comments:

Post a Comment