In this article, we gonna see how to accept only one type of file in HTML form file upload. Eg: Accept only image files in HTML form or accept only js/pdf/text files.
Here is an example of HTML form file upload, which accepts only .js
files

In this article, we gonna see how to accept only one type of file in HTML form file upload. Eg: Accept only image files in HTML form or accept only js/pdf/text files.
Here is an example of HTML form file upload, which accepts only .js
files