How do links within API-created Campaigns get tracked?

SOLVED
Go to solution
Frequent Participant

How do links within API-created Campaigns get tracked?

When uploading raw HTML as the email_content for a campaign how do my <a> links get converted for click tracking (prefaced by http://r20.rs6.net/tn.jsp)?

 

From using Preview & Test functionality, it doesn't seem like the URL's I provide are ready to be tracked as yet...

 

Will the click-tracking URL's generate when the email is sent, or should the be available in the preview? Is there something that I need to call or an attribute I need to supply for CTCT to generate these tracked-click throughs?

 

1 ACCEPTED SOLUTION
Frequent Participant

Well, I figured it out after posting to support directly. Wrapping the <a> tags with <simpleurlproperty> worked.

 

Important: This is an advanced topic and requires previous HTML and XHTML knowledge.

Text links aren't automatically tracked in an email created with XHTML. Code must first be added for each link in your email draft.

To track image links in a custom XHTML template:

  1. Create an email using XHTML in the Advanced Editor.
  2. Click the "Advanced Editor" link on the lower left-hand side of the page.
  3. Click "HTML".
  4. Insert the following code structure for each text link:
    <SimpleURLProperty
    name="mylink"
    track="true"
    label="
    Link Text" href="
    http://www.samplewebsite.com">
    <a href="
    http://www.samplewebsite.com">Link Text</a>
    </SimpleURLProperty>
  5. Update the code in red with the URL for the website you want to link to.
  6. Click Save & Return to continue editing your campaign email.

Once you've added tracking to your image links, don't forget to add it to your image links too!

View solution in original post

2 REPLIES 2
Frequent Participant

Note, I sent one of my API-created campaigns with links to localhost to see if they were somehow converted to tracked-links upon sending to no avail.

 

Please tell me if campaigns generated via API can leverage CTCT click tracking.

Frequent Participant

Well, I figured it out after posting to support directly. Wrapping the <a> tags with <simpleurlproperty> worked.

 

Important: This is an advanced topic and requires previous HTML and XHTML knowledge.

Text links aren't automatically tracked in an email created with XHTML. Code must first be added for each link in your email draft.

To track image links in a custom XHTML template:

  1. Create an email using XHTML in the Advanced Editor.
  2. Click the "Advanced Editor" link on the lower left-hand side of the page.
  3. Click "HTML".
  4. Insert the following code structure for each text link:
    <SimpleURLProperty
    name="mylink"
    track="true"
    label="
    Link Text" href="
    http://www.samplewebsite.com">
    <a href="
    http://www.samplewebsite.com">Link Text</a>
    </SimpleURLProperty>
  5. Update the code in red with the URL for the website you want to link to.
  6. Click Save & Return to continue editing your campaign email.

Once you've added tracking to your image links, don't forget to add it to your image links too!

View solution in original post

Developer Portal

View API documentation, code samples, get your API key.

Visit Page