Detect bad file upload

Limits file uploads by test type (for supported browsers) and displays alerts when a bad file is uploaded (instead of just bombing out)