Support

Account

Home Forums Front-end Issues If statement for True/False field Reply To: If statement for True/False field

  • Hi @will-lawrencefuturform-co-uk

    Could you please make sure that the get_field() function returns the correct value? Could you please debug it like this:

    var_dump( get_field('custom_acf') );

    If that doesn’t return the correct data, it’s possible that the get_field() function is loaded outside of The Loop. In this case, could you please pass the post ID to the get_field() function like this:

    get_field('custom_acf', 99)

    Where ’99’ is the post ID.

    If still no joy, could you please share the JSON or XML export file of your field group so I can check your setup?

    Thanks 🙂