Title: Plugin &#8211; Custom Fields Creator:jQuery shortcode in textarea
Last modified: August 20, 2016

---

# Plugin – Custom Fields Creator:jQuery shortcode in textarea

 *  [NFWRo](https://wordpress.org/support/users/nfwro/)
 * (@nfwro)
 * [13 years, 7 months ago](https://wordpress.org/support/topic/plugin-custom-fields-creatorjquery-shortcode-in-textarea/)
 * Hi
    What a fantastic plugin! I’m using it to display testimonials on a customers
   site. Some of the texts are quite long and when I had them as html text just 
   in a page, I was using the jQuery Collapse-O-Matic plugin to make the divs collapsible
   using the [expand][/expand] shortcodes in the div itself.
 * Is there a way to use this when the text is included in a textarea?
 * Thanks
 * [http://wordpress.org/extend/plugins/custom-fields-creator/](http://wordpress.org/extend/plugins/custom-fields-creator/)

Viewing 1 replies (of 1 total)

 *  Thread Starter [NFWRo](https://wordpress.org/support/users/nfwro/)
 * (@nfwro)
 * [13 years, 7 months ago](https://wordpress.org/support/topic/plugin-custom-fields-creatorjquery-shortcode-in-textarea/#post-3145476)
 * Well I’ve been doing some searching around and it seems that I need to use the
   do_shortcode function from the codex. I’ve tried a number of different ways suggested
   by people in blogs and forum posts, but none of them seem to work in my code.
   I have a custom field that outputs a styled div for customers testimonials on
   a page template with the following code in:
 *     ```
       <?php
       $testimonial = get_post_meta($post->ID, 'testimonial', true);
       foreach($testimonial as $testimonial){
       echo '<div class="testimonial">';
       echo '<p>' . $testimonial['testimonial-text'] . '</p>';
       echo '<p class="testimonialname">' . $testimonial['testimonial-name'] . '</p>';
       echo '</div>';
       }
       ?>
       ```
   
 * I think I need to use the
    `echo do_shortcode('[iscorrect]'.$text_to_be_wrapped_in_shortcode.'[/
   iscorrect]');` from the codex as I have an [expand][/expand] shortcode that creates
   a collapsible div when there is a lot of testimonial text.
 * Can anyone help me as to how to correctly insert this into my code so that it
   is only used when the shortcode is present in the custom field value?
 * Any help very greatly appreciated.

Viewing 1 replies (of 1 total)

The topic ‘Plugin – Custom Fields Creator:jQuery shortcode in textarea’ is closed
to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/custom-fields-creator.svg)
 * [Custom Fields Creator](https://wordpress.org/plugins/custom-fields-creator/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/custom-fields-creator/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/custom-fields-creator/)
 * [Active Topics](https://wordpress.org/support/plugin/custom-fields-creator/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/custom-fields-creator/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/custom-fields-creator/reviews/)

## Tags

 * [custom field](https://wordpress.org/support/topic-tag/custom-field/)
 * [shortcode](https://wordpress.org/support/topic-tag/shortcode/)

 * 1 reply
 * 1 participant
 * Last reply from: [NFWRo](https://wordpress.org/support/users/nfwro/)
 * Last activity: [13 years, 7 months ago](https://wordpress.org/support/topic/plugin-custom-fields-creatorjquery-shortcode-in-textarea/#post-3145476)
 * Status: not resolved