mvc4 url validation
问题 I'm writing this question here after trying to find an answer for two days. basically here's what's going on. I have a property in the viewmodel as follows [Required(ErrorMessage = "Required Field")] [Url(ErrorMessage="Please enter a valid url")] [DisplayName("Website")] public string web { get; set; } in the view, I have this @Html.EditorFor(model => model.web, new { AutoCompleteType = "Disabled", autocomplete = "off" }) now the problem lies in how the input text for this field is validated