So, I’m having this lovely issue where people like to submit invalid file types or funky named files… (like.. hey_i_like_"quotes".docx) Sometimes they will even try to upload a .html link…
How should I check for something like this? It seems to create an error every time someone submits a poorly named item.
Should I create a cfscript that checks it before submission? Or is there an easier way?
When you say submit are you using cffile to allow your users to upload file.
If so, use the attribute “accept” with a try and catch around. for example….
I personally would not use “just” JavaScript as this could be disabled and you are back in the same boat.
Hope this helps.