upload files in form
Hey I have a form that uploads a file. I am having trouble with some of the code and hoping someone can help.
FORM FIELD
<tr>
<td><strong>Upload Submission</strong></td>
<td><input
type="file"
name="submission"
id="submission"
value="#FORM.submission#" class="submissionclass"
/></td>
</tr>
on submission of the form this code runs
PROCESSING CODE:
<cfif FORM.submission EQ " ">
<cfset errors = Errors & "<li>Only PDF, DOC, and DOCX file formats are accepted</li>">
</cfif>
<cfif FORM.submission NEQ " ">
<cfif #right(#FORM.submission#, 4)# NEQ "docx" OR #right(#FORM.submission#, 3)# NEQ "doc" OR #right(#FORM.submission#, 3)# NEQ "pdf">
<cfset errors = Errors & "<li>Only PDF, DOC, and DOCX file formats are accepted</li>">
</cfif>
</cfif>
The questions is will this work or do I have to do it another way.
