Title: Custom fields &#8220;shortcode&#8221;
Last modified: May 7, 2017

---

# Custom fields “shortcode”

 *  Resolved [noapi1](https://wordpress.org/support/users/noapi1/)
 * (@noapi1)
 * [9 years ago](https://wordpress.org/support/topic/custom-fields-shortcode/)
 * Hi,
 * really great plugin!
 * One question for making custom fields: I want to insert a required checkbox, 
   which a user has to check for confirming the usage of his uploaded photo and 
   text. Are these custom fields “shortcode” supposed to do this?
 * I did not find any documentation for “Shortcode on form” and “Shortcode on display”
   fields. How can I realize this with these fields or is it not possible?
 * Thanks in advance.

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

 *  Plugin Contributor [Chris Dillon](https://wordpress.org/support/users/cdillon27/)
 * (@cdillon27)
 * [9 years ago](https://wordpress.org/support/topic/custom-fields-shortcode/#post-9105494)
 * Thanks [@noapi1](https://wordpress.org/support/users/noapi1/).
 * I am behind on documentation.
 * A required checkbox is a frequent request and I plan to add it eventually. Frankly,
   it seems unnecessary since the act of submitting a testimonial implies use of
   its content. But I understand the appeal.
 * The original purpose of the shortcode field was to add links for “Tweet this!”,
   etc. from another plugin. The shortcode field can be a generic approach to add
   whatever you want to the form so it could be used to add a checkbox and store
   the value somewhere but you would need to write that code or hire a developer.
   In your case, you would need the shortcode on the form but not on display.
 *  Thread Starter [noapi1](https://wordpress.org/support/users/noapi1/)
 * (@noapi1)
 * [9 years ago](https://wordpress.org/support/topic/custom-fields-shortcode/#post-9105571)
 * Thank you!
 * Such a checkbox IS in deed unnecessary, but if you live in “the other galaxy”,
   also called EU or Germoney, you HAVE to implement thousands of stupid and really
   obvious things in your site for the only purpose of bureaucracy (see this silly
   cookie-plage).
 * I am able to make the code by myself as I am a developer, but how can I tell 
   your form to make the checkbox mandatory and to show the red error-message if
   it is not clicked? If I make it mandatory nothing happens and I can’t send the
   form. I only need a little hint, as the ckeckbox is already implemented and visible
   with my own shortcode, but there is no function behind.
 * Thank you.
 *  Plugin Contributor [Chris Dillon](https://wordpress.org/support/users/cdillon27/)
 * (@cdillon27)
 * [9 years ago](https://wordpress.org/support/topic/custom-fields-shortcode/#post-9105655)
 * Ah, yes, I see now.
 * The plugin uses the [jQuery Validation plugin](https://jqueryvalidation.org/)
   so if you add the “required” HTML attribute to your field it should be included
   in the validation process. (I have not tested that.)
 * Alternatively, you could enqueue some JavaScript that disables the submit button
   if the checkbox is off.
 *  Thread Starter [noapi1](https://wordpress.org/support/users/noapi1/)
 * (@noapi1)
 * [9 years ago](https://wordpress.org/support/topic/custom-fields-shortcode/#post-9105930)
 * Thanks, done. required did the trick.

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

The topic ‘Custom fields “shortcode”’ 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/)

 * 4 replies
 * 2 participants
 * Last reply from: [noapi1](https://wordpress.org/support/users/noapi1/)
 * Last activity: [9 years ago](https://wordpress.org/support/topic/custom-fields-shortcode/#post-9105930)
 * Status: resolved