Conditional Rendering Based On Meta Box Group’s Sub Field

This Pro tutorial shows how we can output an element on a single post pages only if a specified sub-field (custom field created using Meta Box) inside a specified group has a value.

Given the following scenario where a text-type of sub field having an ID of text_ppe9vzbqld is present inside a group-type of field with an ID of group_7t3lautdysc,

here's the code you would need to add to child theme's functions.php or in a code snippet:

This is a Pro members-only tutorial.

To get full access, login below or sign up for a Pro Account

Leave the first comment