I have a scenario wherein user is trying to view an invalid image file (for example an .dll file renamed to JPG extenstion). How to alert the user using javascript that this is an invalid file
+2
A:
JavaScript, running in the browser in a standard security context, has no way to determine this.
You have to handle this check server side.
David Dorward
2009-11-19 10:44:48