Title: Flex Content Layout using clone field not rendering
Last modified: December 15, 2020

---

# Flex Content Layout using clone field not rendering

 *  Resolved [christdg](https://wordpress.org/support/users/christdg/)
 * (@christdg)
 * [5 years, 5 months ago](https://wordpress.org/support/topic/flex-content-layout-using-clone-field-not-rendering/)
 * I created several groups of fields to use throughout my flexible content layouts.
 * However I cannot call them in the template file as defined in the layout.
 * So heres the setup
 * Group – Title Repeater (titles_repeater)
    Repeater Fields – Title – Tag – Class
 * Then I have a Flexible content field (flex_content) with a layout called “General
   Content Block”
 * This layout has a clone field of the “Group – Title Repeater”
    with the name 
   of (flex_general_content_block_titles)
 * Then for this layout I have defined a template of “flex-content/components/base/
   general-content-block/flex_general_content_block.php”
 * This file should create the front end html when using the call the_flexible(‘
   flex_content’);
 * However I cannot get clone fields to render…I can get a text field to show up
   but all my cloned fields return NULL / false
 * ive tried
    get_field(‘flex_general_content_block_titles’); get_flexible(‘flex_general_content_block_titles’);
   get_sub_field(‘flex_general_content_block_titles’);
 * The above call return respectively
    NULL bool(false) bool(false)
 * Is there a secret or setting I need to get access to the fields in the template
   file?
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fflex-content-layout-using-clone-field-not-rendering%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 1 replies (of 1 total)

 *  Plugin Author [Konrad Chmielewski](https://wordpress.org/support/users/hwk-fr/)
 * (@hwk-fr)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/flex-content-layout-using-clone-field-not-rendering/#post-13858483)
 * Hello,
 * Thanks for the feedback and sorry for the late answer. It looks like you’re struggeling
   to use a clone inside a flexible content layout. The method does not differ from
   the native ACF way to achieve it, using the `get_sub_field()` function. You should
   check the Clone field documentation: [https://www.advancedcustomfields.com/resources/clone/](https://www.advancedcustomfields.com/resources/clone/)
 * There is a code example for clones inside a flexbile content:
 *     ```
       if(have_rows('slides')){
           while(have_rows('slides')){ the_row();
   
               // Clone Button
               $button = get_sub_field('button');
   
           }
       }
       ```
   
 * Considering this, when using the ACF Extended Flexible Content Dynamic Render,
   you can still use `the_flexible('flex_content');`, then in your `layout.php` 
   file, use `$button = get_sub_field('button')`.
 * Hope it helps!
 * Regards.

Viewing 1 replies (of 1 total)

The topic ‘Flex Content Layout using clone field not rendering’ is closed to new
replies.

 * ![](https://ps.w.org/acf-extended/assets/icon-256x256.png?rev=2071550)
 * [Advanced Custom Fields: Extended](https://wordpress.org/plugins/acf-extended/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/acf-extended/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/acf-extended/)
 * [Active Topics](https://wordpress.org/support/plugin/acf-extended/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/acf-extended/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/acf-extended/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [Konrad Chmielewski](https://wordpress.org/support/users/hwk-fr/)
 * Last activity: [5 years, 4 months ago](https://wordpress.org/support/topic/flex-content-layout-using-clone-field-not-rendering/#post-13858483)
 * Status: resolved