Title: error message for missing (required) file upload
Last modified: November 23, 2016

---

# error message for missing (required) file upload

 *  Resolved [hanino](https://wordpress.org/support/users/hanino/)
 * (@hanino)
 * [9 years, 7 months ago](https://wordpress.org/support/topic/error-message-for-missing-required-file-upload/)
 * Hello,
 * when I create a new form field, the checkbox for making the field a mandatory
   adds a required attribute to the input tag. Except for the featured image field(
   <input type=”file”>).
 * Why?
 * Thx!

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

 *  anonymized-13171256
 * (@anonymized-13171256)
 * [9 years, 7 months ago](https://wordpress.org/support/topic/error-message-for-missing-required-file-upload/#post-8474872)
 * Thanks for catching this. I will fix it in the next update.
 *  Thread Starter [hanino](https://wordpress.org/support/users/hanino/)
 * (@hanino)
 * [9 years, 6 months ago](https://wordpress.org/support/topic/error-message-for-missing-required-file-upload/#post-8486238)
 * Hi and thanks again 🙂
 * I changed line 99 in /includes/form-template-functions.php to this:
    `echo '<
   input id="wpmtst_' . $field['name'] . '" type="file" name="' . $field['name'].'"'.
   wpmtst_field_required_tag( $field ).'>';`
 * Please do something similar in the next update. Or give me hint otherwise.
 *  anonymized-13171256
 * (@anonymized-13171256)
 * [9 years, 6 months ago](https://wordpress.org/support/topic/error-message-for-missing-required-file-upload/#post-8492747)
 * This is fixed in version 2.15.

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

The topic ‘error message for missing (required) file upload’ is closed to new replies.

 * ![](https://ps.w.org/strong-testimonials/assets/icon-256x256.png?rev=3134855)
 * [Strong Testimonials](https://wordpress.org/plugins/strong-testimonials/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/strong-testimonials/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/strong-testimonials/)
 * [Active Topics](https://wordpress.org/support/plugin/strong-testimonials/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/strong-testimonials/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/strong-testimonials/reviews/)

## Tags

 * [form](https://wordpress.org/support/topic-tag/form/)
 * [form validation](https://wordpress.org/support/topic-tag/form-validation/)
 * [required field](https://wordpress.org/support/topic-tag/required-field/)

 * 3 replies
 * 2 participants
 * Last reply from: anonymized-13171256
 * Last activity: [9 years, 6 months ago](https://wordpress.org/support/topic/error-message-for-missing-required-file-upload/#post-8492747)
 * Status: resolved