Looking For Something?

Profile Extensions

Purpose

Also referred to as custom profile extensions, or user meta fields, profile extensions is a powerful way to allow users to add information about themselves that is pertinent to your site.

For example, on a dating site, you might add:

  • Gender
  • Marital Status
  • What am I looking for?
  • About me
  • and so on.

Or perhaps, on a gaming site, you might add:

  • Platform (PC, XBOX, PlayStation, etc)
  • Preferred genre (MMO, first person shooter, etc)
  • Do I play multi-player?
  • and so on.

It is only limited by your imagination. And furthermore, not only can you display this information on profile pages, you can add them as an advanced search on your member directory, and include them on your registration screen (mandatory or optional).

After creating a profile extension, the user can set/change that extension on their Edit Profile page.

Creating Profile Extensions

After activating them via WPS Pro->Setup, a new menu item will be available, WPS Pro->Profile Extensions.

To create a profile extension, you would go through the following steps.

Screenshot_22

Enter title here
This is the name of the profile extension, for example “Gender”.

The Editor
A description of the field, which is shown on the user’s Edit Profile page, for example, “Please select your gender.”

Type (in Extension Details box)
You can choose from a variety of types, and depending which you choose, options may appear below.

  • text, a simple text field.
  • textarea, a larger text field, for use with, for example, a field called “More information about me”.
  • list, a set of options that can be selected from a drop-down list. Useful if you want to force the user to choose from a set of values that you define. You can set the values in the box that appears “Values”, seperating each value with a comma. The first value is the default value displayed.
  • URL, allows the user to enter a URL, for example, their Facebook page URL, or website. To force the link displayed to open a new browser tab/window, tick the “open in new window” checkbox. You can also set the Featured Image (probably by scrolling down the screen) which will be displayed instead of the URL. For example, if you are asking users to enter their Facebook page URL, you could choose to display a Facebook icon.
  • date, presents the user with a date picker.
  • image, an image that can be uploaded by the user, and optionally whether they can add a URL that makes the image into a hyperlink. Can choose if a new window opens when clicked on. You can also set this image to be displayed as a profile header image, with the user’s avatar and display name over the top, which is really nice. When uploaded, it will look something like this (you can change the look and feel with CSS).

Screenshot_21

  • YouTube, a YouTube URL (that would be copied from the browser’s web address field when viewing a YouTube video). You can also set the size by enter a width and height. To make the videos responsive, the recommended values are 100% and auto.
  • Divider, this is not actually a field, but is displayed on the user’s Edit Profile page. By setting the order of your profile extensions correctly, you can use this to add headings to your profile extensions. This extension acts slightly differently in that you don’t actually enter a title, but use the editor to set what is displayed, and can therefore use any of the features of the editor.

Order
Set the order in which the Profile Extension appears on the user’s Edit Profile page and if used, the registration page (so long as using the WP Symposium Pro Login & Register extension for user registrations).

Include in Directory Search?
This is only displayed if you have the member directory extension activated. If you check this option, this profile extension will be available under “Advanced Search”. See the member directory chapter for more information.

Include on [wps-login-form]?
If checked, and using the [wps-login-form] shortcode of the Login & Register WP Symposium Pro extension, this profile extension will be included in the registration form.

Mandatory on [wps-login-form]?
Linked with above, this makes the field on the registration form mandatory (must be filled in).

Finally, publish (save) or update if editing, and your profile extension will be created. It will appear on the user’s Edit Profile page, and depending on how you set it up, on the registration page and the advanced search of the member directory. You can now also add your profile extension to a user’s profile page.

Availability

Provided in the Extensions Plugin.

Customising

You can use the global shortcode settings via WPS Pro->Shortcodes in the admin dashboard, or add them to the shortcode as options.

Example

To add a profile extension to the profile page, or any WordPress page or Text/HTML widget, you use the [wps-extended] shortcode as follows.

[wps-extended slug="???"]

Where slug is the slug of the profile extension.

So let’s assume you have a gender profile extension with a slug of “gender”, as a list, with the values “Not telling,Male,Female” from which the user can select via their Edit Profile page. To display this on their profile page with the title as a label you would use:

[wps-extended slug="gender" label_prefix="1"]

You can also show one or more profile extensions for all members on the site with [wps-extended-list].

This is typically used by site administrators to display information collected from all users.

[wps-extended-list]

Tip

In the list of slugs for [wps-extended-list], you can also include the following:

  • ID (user ID)
  • user_login (user login)
  • display_name (user display name)
  • user_email (user email address)
  • user_registered (user registration date)

Options

The following (which shows default values and an example of using the shortcode option) can be set via the admin dashboard (WPS Pro->Shortcodes) or added as options to the shortcode in your WordPress page, post or widget.

[wps-extended]

Text to show if no value set (empty_text=””)
Show it empty (show_if_empty=”1″)
Show label (label_prefix=”0″)

[wps-extended-list]

Seperator character if using multiple slugs, or enter “table” to display as a grid (seperator=”,”)
Viewable by administrators only (admin_only=”1″)
Text to show if no value set (empty_text=””)
Set to a font size, to display in courier font (fixed_font=”0″)
Sidebar