Display Field keys and Group keys

Get Started

Use Code snippet to register shortcode

Explanation:

Group Key Display:
The group key ($grp_key) is now displayed alongside the group name in the tag and also included with each field in the
element.

Output Structure:

The updated function shows the group name, group key, field label, field name, and group key for each field in a clear and structured format.
Now, you can use the [wbcom_profile_fields] shortcode in any post, page, or widget to display all the BuddyPress profile group names and their respective field names.

Example Usage:

Simply add the shortcode to any post or page:

Example Output:

Contact Details (Group Key: bprm_contact_details)

  • Location (bprms_location) - Group Key: bprm_contact_details
  • Phone Number (bprms_phone) - Group Key: bprm_contact_details
  • Email (bprms_email) - Group Key: bprm_contact_details

Work Details (Group Key: bprm_work_details)

  • Job Title (bprms_job_title) - Group Key: bprm_work_details
  • Company (bprms_company) - Group Key: bprm_work_details

Usage:

You can now use this shortcode [wbcom_profile_fields] anywhere on your site to display a comprehensive list of all profile groups, their fields, and associated group keys. This will be particularly helpful when you need to reference the group key while working with these fields.

Last updated: August 30, 2024