WordPress Plugin

Sailthru’s WordPress plugin has been created to get you up and running with your Sailthru account quickly. Its core features will allow you to add the Sailthru JavaScript tag and enable WordPress widgets to personalize the site content and capture user list signups.

Download and Install

The latest version of the plugin (v3.0.6) is available to download as a zip file from the plugin’s GitHub repository.

WordPress VIP platform users already have an earlier version of the plugin available within their installation. (That version, 3.0.1-vip, lacks the Site Personalization Manager features included in the latest plugin version described in this document, however, it will be updated shortly to include those same features.)

Configure

Once you have enabled the plugin, click the new Sailthru link on the left-side menu of the WordPress admin interface, then click the button labeled Add Your Sailthru API & Key.

This release of the plugin adds support for the Sailthru Content API so that the metadata of all your pages, posts, and other content types is pushed to Sailthru when they are created or updated. This will require you to enter your API credentials.

Enter your API Key and Secret (available on your Settings page in My Sailthru), then select a Sailthru JavaScript Version. 

With the release of v3.0.6, you now have the option of using Sailthru’s new JavaScript tagYou can switch versions after setup, but please note that the legacy Horizon JS will be deprecated in early 2017.

The use of the new JavaScript (a.k.a. Personalize JavaScript) will disable the plugin’s legacy Scout and Concierge settings available under Horizon, and a new WordPress widget will provide the ability to render a Site Personalization Manager section on your pages, instead. Speak to your customer success manager about getting set up with Site Personalization Manager and this powerful new functionality.

Click Save Changes. You are brought to the Settings tab of the Welcome page, where you will need to complete additional fields, that differ based on the JavaScript you selected.

If using Personalize JavaScript

Complete/review the following additional fields:

  • Customer Id - This can be found in My Sailthru on the API and Postbacks page (in Settings > Setup), the same page that displays your API key and secret.
  • Ignore Stored Tags – Select the checkbox if you want to manually specify interest tags for each page to attribute to the user’s pageviews. If left unchecked, Sailthru will use the tags in your Content Library (whether added by the Sailthru JS spider or Content API calls).
  • WordPress Template - Select a Sailthru template that you want to use for transactional emails that are sent by WordPress. This should be a template that you have created in Sailthru with {subject} as the subject line. In the body of the email place the Zephyr variable {body}. This will be replaced with email content from WordPress.
  • Override other WordPress system emails? – Select the Yes checkbox if you wish to send all transactional emails through Sailthru.
    The VIP platform has disabled the overriding of all emails via Sailthru, so although this step is necessary for the setup the feature is disabled. This requirement may be removed in later upgrades.

Then, click Save Changes. The JavaScript is now added and properly configured on all of your pages, to enable Sailthru’s Personalization Engine for your site.

NOTE: If you have whitelisting of IP addresses enabled on your Settings page, then you will need to add an IP for your WordPress site if it is not already included. If you do not do this, you will encounter an error when you set up the plugin, as it will not be able to send a template API call to select the WP template.

If using Horizon JavaScript

Complete/review the following additional fields:

  • Sailthru Horizon Domain – Add the Horizon Domain from the My Sailthru Settings >Domains page.
  • Horizon Loading – Select if you want to load the JavaScript synchronously or asynchronously
  • WordPress Template - Select a Sailthru template that you want to use for transactional emails that are sent by WordPress. This should be a template that you have created in Sailthru with the Zephyr variable {subject} as the subject line. In the body of the email place the Zephyr variable {body}. This will be replaced with email content from WordPress.
  • Override other WordPress system emails? – Select the Yes checkbox if you wish to send all transactional emails through Sailthru.
    The VIP platform has disabled the overriding of all emails via Sailthru, so although this step is necessary for the setup the feature is disabled. This requirement will be removed in later upgrades.

Then, click Save Changes. The Horizon JavaScript is now added and properly configured on all of your pages.

NOTE: If you have whitelisting of IP addresses enabled on your Settings page, then you will need to add an IP for your WordPress site if it is not already included. If you do not do this, you will encounter an error when you set up the plugin, as it will not be able to send a template API call to select the WP template.

Sailthru Meta Tags

Simply by adding your Sailthru account settings you’re already ready to go with Personalization Engine. The plugin will automatically add the necessary JavaScript to the footer of your theme. We’ll also automatically add the necessary Sailthru Meta Tags to your page for you. When you tag a piece of content in WordPress you won’t have to worry about adding those meta tags to the post/page, it’ll be there for you.

For tagging content the plugin will use the default WordPress tags field available when you are creating or editing content. For more control over the tags you send to Sailthru, there is also a Sailthru Meta Tags field on the page which will be used instead of the WordPress tags field if it has comma separated tags present. This is often desirable when your WordPress tags are best suited for other purposes, such as SEO, but not as well-suited for content filtering and user-interest tagging in Sailthru.

If neither the WordPress tags field or Sailthru Tags field are completed, then we will default to using the category selected in the post/page as the lone content tag for Sailthru.

Expiration and Tags

Expiring Content

Sometimes you do not want your content displaying in future recommendations. So for each post/page you’ll be able to set the content expiry date. This will tell Sailthru to remove this piece of content from Sailthru recommendations after the set date.

Concierge Setup (for Horizon JS only)

Concierge is a Personalization Engine-powered on-site recommendation tool, allowing a small “slider” to appear in a user’s browser window at the end of an article. The slider will suggest another story based on a user’s interest. (The recommended method for implementing this feature is now to use the new Personalize JavaScript with Sailthru’s Site Personalization Manager. This offers the same display to your visitors, but with a wide array of additional options for configuration and metrics.)

To enable Concierge on your site click on the Concierge tab and check the box and click save. Once enabled you’ll be presented with a simple form to configure Concierge behavior.

For full documentation on Concierge options check out the Concierge documentation page. The plugin simple makes those options available via a form.

Scout Setup (for Horizon JS only)

Scout is an on-site tool that displays relevant content to users when viewing a particular page. The tool is powered by Sailthru’s Personalization Engine intelligence, which gathers data on your users’ individual interests, based on activity on your website, mobile device and tablet, all tied to each user’s email address.

To enable Scout on your site click on the Scout tab and check the box to enable it. You’ll be presented with a screen allowing you to configure the options via a simple form.

Widgets

The Sailthru plugin provides two widgets. The first “Sailthru Recommends” is a widget that displays recommended content via Scout. If you’ve enabled Scout then you’ll be able to use this widget anywhere your theme allows you to place content. The content provided by Sailthru Recommends is powered by Personalization Engine and so recommends content based on the Personalization Engine domain field that you provide in the plugin settings screen.

Subscribe Widget

We’ve also provided a simple “Subscribe” widget which you can use to easily provide signup for newsletters. You’ll be able to add users to one or more lists when they sign up. Quick and easy.

By default the widget displays an email field but you can add additional fields to the widget if you’d like to gather more information from your subscribers. To use this feature click on the Subscribe Widget Fields in the Sailthru admin screen.

The screen displays any fields you have already configured and a form to easily add new ones. Any fields added to the admin will be available to all widgets. You can add a number of different HTML fields that can be used for different types of information, for example a “select” field can be used for data like gender.

Text fields are used to collect information where the user will type in their answer, select fields are drop down fields that can be used for fields like State or Country. Hidden fields are not visible to the user but allow you to gather information that might be important to you such as the source of the campaign.

Shortcodes

The subscribe widget is available as a shortcode too using the following syntax.

[sailthru_widget fields="names,of,fields" sailthru_list="list_name"]

Parameter

Description

Values

fields

Comma separated list of field names as displayed on the Subscribe Widget Fields admin screen.

field name(s)

modal

Display widget as a modal window

(optional) true  or false

sailthru_list

comma separated list of lists to add the user to

list name(s)

Sailthru Personalization Engine Widget

This widget gives you the option to render a Site Personalization Manager section directly on your page, combining the power of Sailthru’s personalization and WordPress’s drag and drop interface.

When you select Personalization Engine Javascript as the option this widget will allow you to select from your available SPM sections.

Wordpress SPM Widget

You’ll find both these widgets in WordPress’s Widgets section.

Filters

WordPress themes provides a method to override some of the plugin’s default features. For example you may not want to include a specific sailthru tag like a date. Or you want to combine the sailthru meta tags with the category tags.

The plugin has three tags to allow developers to customize the output of Personalization Engine meta tags. To use the filters you can use these filters within your theme’s functions.php file. If the file does not exist you can create it. For more information see the WordPress documentation on filters.

sailthru_horizon_meta_tags_enable returns boolean false to prevent the Personalization Engine meta tags from outputting. Useful when you wish to rely on the fall back meta tags or manually output your own.

sailthru_horizon_meta_tags is supplied an array of the name/content attributes of the meta tags. This is helpful if, for example, you need to update the value of sailthru.author when using a plugin like co-authors-plus, or for swapping out sailthru.tags for categories or a terms from a custom taxonomy.

sailthru_horizon_meta_tags_output this filter acts on each meta tag, allowing you to edit each html tag.

See the examples below for more context.



          
          
          
                
Top