How to Catch multiple file from form?

  • Profile Image
    ltea
    Asked on March 24, 2012 at 06:36 AM

    Hi.

    I have a form with file multiple fields, and Im using my own php script in the action for the form.

    Ive changed the field name from
    <input class="form-upload-multiple" type="file" id="input_14" name="q14_cfp[]" multiple="multiple" file-accept="pdf" file-maxsize="10240" />

    TO
    <input class="form-upload-multiple" type="file" id="input_14" name="CFP[]" multiple="multiple" file-accept="pdf" file-maxsize="10240" /> 

    But when I try to catch the variable of the field that would be CFP[] it doesent appear to pass (PHP), all other fields pass just fine to the destinantion page, am I missing something?.

    Regards

    LT

  • Profile Image
    gori-mathew
    Answered on March 24, 2012 at 08:30 AM

    Hello;

    On downloading multiple files from forms can be achieved by enabling 'allow multiple tab', check on the following links to guide you;

    http://www.jotform.com/answers/86172-Multiple-File

    http://www.jotform.com/answers/25825-best-way-to-download-files

    http://www.jotform.com/answers/86172-Allow-multiple-file-upload-field-option-does-not-seem-to-work

    Hope you find this information helpful and feel free to contact us with any question.

     

     

  • Profile Image
    ltea
    Answered on March 24, 2012 at 02:44 PM

    Thanx, bot the problem is hat the variable is not passing to the action page, if I submit the form and I do a print $_FILE['CFP']; on the php side the variable returns empty

    as Ive said, I changed the field name from

    <input class="form-upload-multiple" type="file" id="input_14" name="q14_cfp[]" multiple="multiple" file-accept="pdf" file-maxsize="10240" />

    TO
    <input class="form-upload-multiple" type="file" id="input_14" name="CFP[]" multiple="multiple" file-accept="pdf" file-maxsize="10240" /> 

    but returns empty on the other side ($CFP[ ] variable) in fact, it does not exist on the other side.

  • Profile Image
    ltea
    Answered on March 24, 2012 at 02:47 PM

    All other variables pass from the form to the processing page fine :s

  • Profile Image
    fxr
    Answered on March 24, 2012 at 05:04 PM

    The upload may be done via javascript. 

    I dont think what your doing in bypassing JotForms servers for your forms submissions will be viewed in a great light by JotForm management so if you do want to pursue this idea, it may be better if you don't ask for any help doing it. 

    You may also want to consider a JotForm liciensing solution if you want to manipulate and/or enhance existing JotForm functionality. 

    http://www.interlogy.com/products/jotform/