Home Forums General Issues True/False Field in Flexible Field


True/False Field in Flexible Field

  • I’m having an issue with a True/False Field always returning ‘false’ when used inside a Flexible Field. I’m wondering if there’s a specific way it needs to be used in this context?

    • Elliot

    • October 29, 2013 at 5:59 pm

    Hi @brunocloutier

    Perhaps you could post a screenshot of the back-end data and then the code you are using to render it?


  • Of course! Here’s the (simplified) code and the attached screenshot of the back-end data. The back-end is in french, hope it won’t cause any problem.

    <?php elseif(get_row_layout() == 'image-5') : ?>
    <?php var_dump(get_sub_field('keep_grouped')); ?>
    <?php endif; ?>

    I’ve been able to make it work correctly outside of a Flexible Field.

    Thank you!

    • Elliot

    • October 30, 2013 at 4:34 pm

    Hi @brunocloutier

    print_r won’t show a true / false. Can you use var_dump instead?


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

You must be logged in to reply to this topic.

We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Cookie Policy. If you continue to use this site, you consent to our use of cookies.