Tuesday, August 17, 2010

Adding and Tracking Facebook ‘Like’ buttons in Eloqua emails


(Guest post from Vince Lockyer, Demand Gen Specialist, Avid)
vince (d0t) lockyer (at) avid (dot) com

There have been a lot of blog posts recently about Facebook ‘Like’ buttons and how to use them in marketing emails.

While it’s easy to add a link to a Facebook group or page from an email, it’s not been so easy to integrate a fully working ‘Like’ button into an email in a similar way it works with a webpage – and also accurately track who’s clicking it and what they are ‘liking’.
So far only one or two vendors have come up with an embedded solution to this – which of course only works with their platform. Now using the method described here you can get the same functionality for your Eloqua emails. This solution requires a bit of HTML tweaking in the final step.

How it works
From your Eloqua email, a blind form-submit sends the email address of the recipient, the URL, and the name of the webpage being ‘liked’ to an Eloqua form. After logging and tracking these details the form confirmation page then displays the webpage overlaid with the Facebook Like Button Social Plug-in.

Try it out!
Try out this example form with your own data to see how it looks.

How to build it

Create two new contact fields:
• Facebook – Last Like URL
This will contain the URL of the last thing that the contact liked. It’s required also because the form confirmation page will need the URL to display the webpage in the final step.

• Facebook – Last Like Name
(Optional but highly recommended.) Contains the name of the last thing that the contact liked. Required to make the reports more readable and also to be displayed in the form confirmation page.

Create a new form with the following fields. Keep the form name and the HTML names of the fields short as they will be used in the blind form submit URL. Try something like ‘fb’ or ‘like’ for the form name.

• ‘e’ – Email Address
• ‘l’ – URL
• ‘n’ – Name

Add a ‘Update Contact Data’ processing step to update the two Facebook fields from the form submissions.

Add a confirmation page processing step. Here you will need to build the HTML for displaying the webpage overlaid with the Facebook Social Plug-in.

Confirmation Page HTML
The confirmation page displays the webpage being ‘liked’ in an iframe embedded in the Eloqua confirmation page. A semi-transparent layer is overlaid on top with the Facebook Social Plug-in contained in another layer (see image).

A close button is included in the top-left that hides the overlaid layers and reveals the webpage beneath.

Download the HTML for the confirmation page, you can use it as-is or customise it to your requirements. Note: you will need to edit it to update the field merges and locations of the graphics files in your Eloqua instance.

To add-in your own field merges for the ‘Facebook – Last Like URL’ and ‘Facebook – Last Like Name’ use the Insert Contact Field option in the Eloqua Confirmation Page editor. To upload the images use the Upload Images tool under Hypersites or Email Marketing > Tools & Content Components. You’ll need to copy the URL of the hosted image once uploaded and paste that into the HTML.

Adding the Like button to an email

Once the form fields, form and confirmation page is setup you can add the ‘Like’ button to your email. The button will trigger a blind-form submission in this format:



Make sure “?elqFormName=” equals the HTML name of the form you created and “&elqSiteID” equals your unique Eloqua site ID. “&l=” is the URL of the webpage being liked and “&n=” is the name.

Reporting

To get a report of who is liking what, view the Form Data report:


Liking or Recommending

The code described here will allow you to add a ‘Like’ button. You can also add-in a ‘Recommend’ button using the same code – you’ll just need to change the ‘action’ parameter in the Facebook Social Plug-in to ‘recommend’:
“&action=recommend”

2 comments:

JM Caballero said...

Does one need to add the Open Graph Protocol to the URL that someone is "Liking" for it to work? I am just testing this idea out as I don't have access to our corporate website.

Vince Lockyer said...

Hi JM. No, you only need the original URL of the page. The social plug-in takes care of the rest.