I’ve set jquery.unobtrusive-ajax.js and jquery.js file and in web.config I’ve set
<add key="ClientValidationEnabled" value="true" />
<add key="UnobtrusiveJavaScriptEnabled" value="true" />
But it still refreshes the page instead of doing javascript validation.
Also my model has:
[Required(ErrorMessage = "Reguired")]
public string UserName { get; set; }
[Required(ErrorMessage = "Reguired")]
public string Password { get; set; }
Please help
You need to
add jquery.validate.jsandjquery.validate.unobtrusive.jsin that order.jquery.unobtrusive-ajax.jsis to make Ajax.* helpers work, it has nothing to do with validation.