performance - Enable files extensions with jQuery validate -


the code works half well, can not check file extensions. how enable feature when user types in wrong file formats displays error message?

 $(document).ready(function () { jquery.validator.setdefaults({ success : "valid" }); var validator = $("#myform").validate({     rules : {         "file1" : {             required : true,             extension : "slx|mdl",             accept : false         },         "file2" : {             extension : "m",             accept : false         },         "file3" : {             extension : "xlsx|xls",             accept : false         },         "file4" : {             extension : "pdf",             accept : false         }       } }); });     


Comments

Popular posts from this blog

html - How to set bootstrap input responsive width? -

javascript - Highchart x and y axes data from json -

javascript - Get js console.log as python variable in QWebView pyqt -