Complex Custom Validation in Foolproof Validation
问题 I have implemented Complex custom Foolproof validation in my application from this link but sadly its not working.My requirement is simple,I have a input file for uploading an image and there should be a validation if the user chooses to upload file other than specified below ".jpg",".png",".gif",".jpeg" Code is [Required(ErrorMessage = "Please upload Photo", AllowEmptyStrings = false)] [IsValidPhoto(ErrorMessage="Please select files of type .jpg,.png,.gif,.jpeg")] public HttpPostedFileBase