Title: Attachments file names
Last modified: September 7, 2020

---

# Attachments file names

 *  Resolved [ec049](https://wordpress.org/support/users/ec049/)
 * (@ec049)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/attachments-file-names/)
 * Hello, I’m strarting to use the plugin, im using it and works fine.
 * Im making a form with modals, first modal have the form with the plugin for upload
   the files, and the second modal to confirm the fields values as a summary to 
   confim before send it.
 * ¿How I can show the filenames at the second modal with JS?
 * For contact form I am using function with that and its working well, but I don’t
   get how to do that with Drag and Drop Multifile Upload CF7 plugin:
    var name 
   = $(‘.wpcf7 input[name=your-name]’).val(); document.getElementById(‘modalIdname’).
   innerHTML = name;
 * Thanks in advantage.

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Glen Don Mongaya](https://wordpress.org/support/users/glenwpcoder/)
 * (@glenwpcoder)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/attachments-file-names/#post-13371759)
 * Hello [@ec049](https://wordpress.org/support/users/ec049/) ,
 * Can you try this?
 *     ```
       var $fields = jQuery('input[name^="uploader-249"]');
       var $names = [];
   
       jQuery.each( $fields, function(i,v){
          var val = jQuery(v).val();
          $names[i] = val.replace(/.*\//, '');
       });
   
       // Log $names (you may append name above inside .each )
       console.log($names);
       ```
   
 * Just change **“uploader-249”** to the correct name of your fields.
 * I hope that will help.
 *  Thread Starter [ec049](https://wordpress.org/support/users/ec049/)
 * (@ec049)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/attachments-file-names/#post-13372577)
 * Hello [@glenwpcoder](https://wordpress.org/support/users/glenwpcoder/) that’s
   worked for me, so much thanks!!!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Attachments file names’ is closed to new replies.

 * ![](https://ps.w.org/drag-and-drop-multiple-file-upload-contact-form-7/assets/
   icon-128x128.jpg?rev=1984850)
 * [Drag and Drop Multiple File Upload for Contact Form 7](https://wordpress.org/plugins/drag-and-drop-multiple-file-upload-contact-form-7/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/drag-and-drop-multiple-file-upload-contact-form-7/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/drag-and-drop-multiple-file-upload-contact-form-7/)
 * [Active Topics](https://wordpress.org/support/plugin/drag-and-drop-multiple-file-upload-contact-form-7/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/drag-and-drop-multiple-file-upload-contact-form-7/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/drag-and-drop-multiple-file-upload-contact-form-7/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [ec049](https://wordpress.org/support/users/ec049/)
 * Last activity: [5 years, 8 months ago](https://wordpress.org/support/topic/attachments-file-names/#post-13372577)
 * Status: resolved