1

Does anyone know why the filename or names do not always record in the freeform table? Ex. my form is located in exp_freeform_form_entries_1. the file field is form_field_22. But on many of my forms, this field is blank.

I'm using ff pro v.4.0.12

My code is below

        <p><label for="file_field0">Please upload your file: (File format: .docx or .pdf)</label>
                <input type="file" id="file_field0" name="file_field0[0]" class="required" /></p>

Any help is appreciated.

Peter T

1

OK, I'm just about there. I was trying to combine multiple uploads into one field. So I am now using two file upload fields and the fields were successfully entered into the form database table.

My issue now is that on the update form (exp:freeform:edit), I am only able to view one of the files. My code is below:

    <fieldset>                    
    <p><label for="380"><strong>Statement of Interest</strong>: (File format: .docx or .pdf)</label>
            {freeform:field:file_statement show="1"}</p>

    <p><label for="379"><strong>Transcript</strong>: (File format: .docx or .pdf)</label>
            {freeform:field:file_transcript show="1"}</p>

        <input type="hidden" name="completed" id="completed" value="Yes">
    <p><input type="submit" name="submit" class="btn btn-primary" value="Submit" /></p>

</fieldset>

I can't find documentation that states how to view and update multiple files on the freeform:edit form. Any help is appreciated. Peter T

0

Can you post more of your template code? Does a file get uploaded? Are you saying that it works sometimes?

Im not sure why your name attribute has the '[0]'

I have a form and the input looks like this:

<p><strong>Attach file:</strong><span class="required_field">*</span>  <input type="file" name="file1" class="required" accept="doc|docx"/><br/>5 MB max. MS Word format .doc or .docx</p>
1
  • Are you using freeform pro v4.0.12? This code didn't work for me. I use the file[0] code based on this post (expressionengine.stackexchange.com/questions/16682/…) and it works every now and then. Meaning that the filename is entered into the form database (exp_freeform_form_entries_1) But more often the column in this db is empty. The file is uploaded into the exp_freeform_file_uploads table. Weird. – user1469 Mar 4 '14 at 3:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.