I tried to use the accept of input type="file" with accept to have string as ".doc,.docx,.txt,.rtf" but it still shows .csv.js and .spec.js files
<input type="file"
accept=".doc,.docx,.txt,.rtf"./>
I tried to use the accept of input type="file" with accept to have string as ".doc,.docx,.txt,.rtf" but it still shows .csv.js and .spec.js files
<input type="file"
accept=".doc,.docx,.txt,.rtf"./>
The problem is that the accept parameter uses the MIME Type, so it may not work .doc Uses MIME Type for different versions:
.doc application/msword .dot application/msword
.docx application/vnd.openxmlformats-officedocument.wordprocessingml.document
.dotx application/vnd.openxmlformats-officedocument.wordprocessingml.template
.docm application/vnd.ms-word.document.macroEnabled.12
.dotm application/vnd.ms-word.template.macroEnabled.12
If you need other types https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Complete_list_of_MIME_types