1. checking file type (\.jpg|\.jpeg|\.png|\.gif).
2. Checking file Size between min 2MB and max 4MB.
to download this code, right click on this page and "View Page Source" or "Ctrl + U"