Skip to main content

How to Set Up a Repeater Field in Insert/Update CPT or CCT Forms

Updated over 11 months ago

Setting Up a Repeater Field for CPT

  1. Create the Repeater Field:
    In the form, ensure the names of Repeater field and fields inside the repeater in your form match the names of the metafields in your Custom Post Type (CPT) exactly. This is essential for the form to recognize and save data correctly.

  2. Post Submit Action:

    • Set the action to Insert/Update Post to save the form data to your CPT.

    • Verify that each field in your form matches the field names in the CPT for proper data mapping.

  3. If it's edit post form, don't forget to set up Preset. All form fields should be mapped to their metafields

Setting Up a Repeater Field for CCT

  1. Field Name Matching:

    • First, ensure the names of the repeater field and its subfields in the form match the metafield names in your Custom Content Type (CCT).

  2. Configure Field Mapping in action:

    • In the Insert/Update Custom Content Type action, map Repeater form field to the corresponding CCT repeater field.

  3. Preset settings:

    • If it's edit CCT form, you will also need to set up Preset. Make sure all fields are attached to the same Repeater metafield.

By following these steps and ensuring all field names are consistent, you’ll successfully set up a repeater field for CPT or CCT forms in Crocoblock.

Did this answer your question?