New

We just released a new plugin bundle: Struninn - Elementor Plugins Bundle! We'll be having a discount price for just a few days, so hurry up and check it out!

Our Envato Profile

Documentation

Vikinger – BuddyPress and GamiPress Social Community

wordpress

buddypress

gamipress

bbpress

woocommerce

react

BuddyPress

Profile Fields

You can customize which fields you want to add to your users profile, such as bio fields, personal information, interests and social network links by using the BuddyPress Profile Fields functionality. Each of the fields you create will be available to every user on their respective settings screen where they can fill them with information that will then show in the different parts of the site (e.g. users can fill social links information and the links will show in their profile header and profile preview cards).

Profile field groups

Before you start customizing your desired profile fields, you need to create the base profile Field Groups that the theme uses to display them. The Field Groups that the theme uses are:

Profile_Bio

Used to display bio information about the users. Users complete this information by going to their Profile Info settings screen. The completed information is displayed on the users About Me widgets on their profile timeline and profile about pages, and on their profile preview cards.

Profile_Personal

Used to display personal information about the users. Users complete this information by going to their Profile Info settings screen. The completed information is displayed on the users Personal Info widget on their profile about pages.

Profile_Interests

Used to display things the users are interested in. Users complete this information by going to their Profile Info settings screen. The completed information is displayed on the users Interests widget on their profile about pages.

Used to display users social links. Users complete this information by going to their Social settings screen. The completed information is displayed on the users profile header on any of their profile subpages and on their profile preview cards.

Account_Info

Used to display account info about the users. Users complete this information by going to their Account Info settings screen. This information is private to the users and is not displayed anywhere on the site. Used to allow users to change their displayed name.

Creating profile field groups

To create the Field Groups the theme uses, follow these steps:

  • Go to your WordPress admin panel.
  • Go to Users -> Profile Fields.
  • Click on Add New Field Group.
  • Enter the group name, in this example we are going to create the Profile_Bio group.
  • Click on Save after entering the group name.
  • Go to the Profile_Bio group tab that was created and click on Add New Field.
  • Enter About as the field name and select Multi-line Text Area as the field type (this is the only fixed name field that you need to create because we use it to show it in a specific way in the profile about widget and profile preview cards).
  • Click on Save to create the field.
  • The field will now show in every user Profile Info screen.
  • Enter some information and click on Save Changes.
  • The information you entered will now appear in the About Me widget on the users profile timeline, profile about pages and on their profile preview card.

You can follow the same steps to create the other profile field groups and add fields to them.

Profile field / group localization

The theme uses the BuddyPress xProfile groups and fields to allow site members to enter information about themselves, like bio, personal, interests, social links and account information.

To be able to show each xProfile field group and its respective fields in different settings pages and widgets in the members profiles, the theme has to query them by their name.

This creates problems if users need to edit group or field names for translations purposes, as the theme won’t be able to find and display the group or field information if the name is not the one it is expecting.To solve this and allow users to translate them, we have included a new customizer section with this update (“Vikinger Settings” -> “xProfile Groups / Fields”).

To understand how to edit the profile groups and fields for translation purposes, we need to detail how the theme uses the group names.

xProfile group names consist of a prefix part (i.e. “Profile”) followed by an underscore (_) followed by the subgroup name (“Bio”): “Profile_Bio”.

The prefix part (in this example “Profile”) is used to identify on which settings page the group and all its fields will be displayed in, to allow members to edit their information:

  • “Profile” prefix: groups and fields display on the member profile info settings screen (Profile_Bio, Profile_Personal, Profile_Interests).
  • “Social” prefix: groups and fields display on the member social settings screen (Social_Links).
  • “Account” prefix: groups and fields display on the member account info settings screen (Account_Info).

The prefix part of the xProfile group names shouldn’t be changed, otherwise the sub groups and fields won’t display correctly in the settings pages.

The subgroup name part (in this example “Bio”) is used to identify on which member profile page widget the subgroup fields are going to be displayed in (in this case, the “About Me” widget).

This subgroup in particular also has a special case with its “About” xprofile field, which is displayed differently from the other fields (text only at the top of the widget after the title).

With this update, users can now edit all subgroup names from the backend “Users” -> “Profile Fields” page to translate them and then enter that same name on the respective customizer “Vikinger Settings” -> “xProfile Groups / Fields” option.

This allows the theme to query the subgroup using the new name and display the information correctly on each widget.

As we mentioned before, the “Profile_Bio” “About” field is a special case and if changed, its new name has to be entered in the customizer.

Any other xProfile field names can be changed and will display correctly without the need to enter their new names in the customizer.

To summarize:

  • xProfile group name prefix shouldn’t be changed.
  • xProfile subgroup names can be changed to translate them, but the new subgroup name has to be entered in the respective customizer “Vikinger Settings” -> “xProfile Groups / Fields” option.
  • Any xProfile field names can be changed to translate them without further changes, except the “Profile_Bio” “About” field whose new name has to be entered in the respective customizer “Vikinger Settings” -> “xProfile Groups / Fields” option.