Your Knowledge Base has moved to the new Help Center.  Check out the release notes for details. And don't forget to update your bookmarks and in-house documentation before May 28.

Text & Tokens

 

Basics

Ready to choose your own adventure? The Text & Tokens Insight lets you do that! Brush off those HTML and SQL skills and create some truly amazing and helpful Record Insights to help your Users do ministry better. Remember to share your Insights in the forums so we can learn from each other!

  • Text & Token Record Insights pull essential information and put it front and center. Think of these as your new and improved Contact Cards. 
    • Contacts Page: Participant information
    • Participants Page: Contact information
    • Care Cases Page: Contact information
    • Care Cases Page: Participant information
    • Donors Page: Contact information
    • Donors Page: Participant information
    • Donations Page: Contact information
    • Donation Distributions: Contact information
    • Donation Distributions: Donation information
  • The text & tokens Record Insight is based on a mixture of HTML and tokens. Pro tip: Work in source code mode.
  • Tapping the email address in one of the pre-loaded Record Insights will open your email app so you can send that email ASAP.
  • Use FontAwesome icons to make your Record Insight, well, awesome.
  • Use the Advanced Search Tool to create the tokens that will be rendered for each record.
Important: If you use the Advanced Search Tool to get the information for the tokens, it will look like this: primary_contact_table.[email_address]. But for the purposes of Record Insights, you'll need to move the left square bracket at the very start of the ID, so it looks like this: [primary_contact_table.email_address]. It's going to look weird the first time you do it, but we promise it's okay. Just make sure the entire ID is in square brackets and that there are only two square brackets (one at the beginning and one at the end). And note, you have a 128 character limit between those brackets.

Configuration

MinistryPlatform comes preloaded with a whole bunch of Record Insights. But if you want to add your own, you can do that if you have access to the System Setup section. Here's how ...

  1. System Setup > Insights
  2. Click the "+" to create a completely new Record Insight. Or find one you like and hit that copy button.
  3. Add/Edit the desired information
    • Title: A friendly title for your Record Insight. Make it clear and concise. Note: The title will not appear on the text & tokens Record Insight.
    • Page: The page where the record insight will be displayed.
    • Sub Page View: Leave blank
    • Template: Template? We don't need no template!
      1. Switch the Template field to source mode by tapping the "</>" button. Pro tip: Maximizing the field will make everything easier.
      2. Use HTML and tokens to create the Record Insight you want to see in the world. 
      3. If you used the Advanced Search Tool to get your tokens, be sure to move that left bracket to the start of the clause.
      4. Note: The token value must be either the Table Field Name or Table Field Path.
    • View Order: The order this insight will appear in, from left to right.
    • Active: Whether the insight will show up on the page. No longer relevant, set this to No.
  4. Save

Text & Tokens Examples

Copying the example below is a great way to go! But be sure to switch the Template field into source mode (by taping that "</>" button) before pasting.

Contact Card for Group Primary Contact

<h3 style="text-align: center;">Primary Contact Card</h3>
<div style="text-align: left; padding-left: 15px;">
     <b> Attends:</b>[Primary_Contact_Table_Household_ID_Table_Congregation_ID_Table.Congregation_Name]
</div>
<div style="text-align: left; text-transform: lowercase; padding-left: 15px;">
     <br><i class="fas fa-envelope-open-text" style="color: #4fb2cc;"></i> [Primary_Contact_Table.Email_Address]
     <br><i class="fas fa-mobile-alt" style="color: #4fb2cc;"></i> [Primary_Contact_Table.Mobile_Phone]
     <br><i class="fas fa-sms" style="color: #4fb2cc;"></i> [(SELECT CASE WHEN Primary_Contact_Table.Do_Not_Text = 0 THEN 'Allows Texts' ELSE 'Do Not Text' END)]
     <br><i class="fas fa-birthday-cake" style="color: #4fb2cc;"></i> [Primary_Contact_Table.Date_of_Birth]
</div>

Address Fields (note the extra bracket on the city/state code - it's not a mistake ;)

[Household_ID_Table_Address_ID_Table.Address_Line_1] [Household_ID_Table_Address_ID_Table.City]
[Household_ID_Table_Address_ID_Table.[State/Region]] [Household_ID_Table_Address_ID_Table.Postal_Code]

Contact Card with Clickable Phone Number

<div style="text-align: center;"><b>Household Information</b></a></div>
<div style="text-align: center;">The [Household_ID_Table.Household_Name] Family</div><b>
  <div><b><br></b></div>Home Phone
</b>: <a href="tel:[Household_ID_Table.Home_Phone]">[Household_ID_Table.Home_Phone]</a>
<div>
  <div><br></div><b>

    Address</b>:
  <br>[Household_ID_Table_Address_ID_Table.Address_Line_1]
  <br>[Household_ID_Table_Address_ID_Table.City],&nbsp;[Household_ID_Table_Address_ID_Table.[State/Region]]&nbsp;[Household_ID_Table_Address_ID_Table.Postal_Code]
</div>