Currently, I am working on an application where I am facing a challenge related to file uploads. Specifically, I have an input field like this:
<input id="full_demo" type="hidden" name="test[image]">
I am looking for a way to restrict the upload of only .jpg files. Is there any method or technique available that can help me achieve this?
In my code, changing the input type from "hidden" to "file" poses an issue with the cropper plugin not functioning as expected.
Although I attempted the following code snippet, it did not work as intended:
<input type="file" name="pic1" accept="image/jpeg" />