[memb_contact]

Summary

This shortcode pulls up any piece of information (contact details, custom fields, etc.) from the member’s ActiveCampaign contact record.

Shortcode Examples

To show first name you would use:

[memb_contact fields="firstname"]

To show first name and last name with one space between them you would use:

[memb_contact fields="firstname,lastname" separator=" "]

The easiest way to find the field names is to open a user in WordPress and scroll down until you see the Memeberium data (screenshot below)

Then you’ll use the names without the % signs. For example, “email” “firstname” and “textareatest” would all be valid field names.

Examples of Post Processing:


Here are two examples of post processing. The first one will make all letters lowercase and then capitalize the first letter of each word. The second example will make all letters lowercase and only capitalize the first letter of the first word. For more functions you can use, visit this link.

[memb_contact fields=firstname txtfmt=strtolower,ucwords]
[memb_contact fields=firstname,lastname txtfmt=strtolower,ucfirst]

Shortcode Parameters

capture:  Capture the output of the shortcode and route it to a variable for later use. (?)

contact_id:  The contact ID of a different contact.  Optional.

date_format: The date formatting to use for your field.  You can read more about the date formatting options here.

default: The default value to display if the field is empty or doesn’t exist

htmlattr:  The HTML attribute to use if this shortcode is embedded inside of an HTML tag.

fields: A comma separated list of fields from the Contact table.  You can use the field placeholder here with or without the % symbols.

separator: The string to use to separate the list of fields when output. The default separator is a single space.

txtfmt: A comma separated list of text processing functions to be used to post process the contact fields. (?)

Description

This shortcode is your swiss army knife for displaying any and all information about the contact, and to give you control over the output of that content.

Features include the abilities to:

...capture the field contents to a local variable.

...display a field belonging to another contact.

...display a default value, if the field is empty.

...display multiple fields, and separate them with text of your choice.

...Format the output using Memberium's text formatting functions.

...Format date fields into the format of your choice.

Shortcode Attributes

Conditional: No (?)
Nestable: No (?)
Accepts formatting: Yes (?)
Capturable: No (?)