Oxygen has built-in integration (Repeater component) of Meta Box for showing the sub fields of a group without writing code. It does the job in most situations.
But there could be certain cases where you need 100% control on the HTML output or perhaps you are not using Oxygen and in this members-only tutorial we share sample PHP code for the same.
Consider the following scenario:
- Field Group name: Product Fields
- ID of Group-type of cloneable and sortable custom field:
Product Documents
- ID of Text-type of field:
document_title
- ID of File Input-type of field:
document
- ID of Text-type of field:
- ID of Group-type of cloneable and sortable custom field:
json export of the field group can be downloaded from here.
The HTML output we are going for:
PHP:
This is a premium members-only content.
To view the rest of the content, please sign up for membership ($47/month or $599 one-time).
Already a member? Log in below or here.