When URL's are passed as targetData from the workflow to the content form they are not marked for personalization and no tracking information is added. Is there a way to ensure they are detected and the proper tracking information is appended?
use this documentation for your reference and follow the instruction given there then you will be able to track them.
Feel free to reach out to us if you need more information.
I did read this documentation and at first it seemed like it would work however I am not understanding the implementation. The URL is passed from the workflow (e.g., targetData.myUrl has a value of 'https://www.mywebsite.com/') and can be unique per recipient however the detection of tracking links happens before the personalization process so these URL's are not appended with the respective tracking information.
I wanted to preprocess this targetData so that the tracking analysis would see these links, however the object isn't available in the @value instructions.
what you are doing falls under dynamic vale, so you have two options:
Option 1: Use <a href="http://<%=targetData.myURL%>"> myURLwill have value without the protocol part, but this is not recommended.
Option 2: Use <%@ value
This instruction gives access to parameters of the delivery that is constant for all recipients.
<%@ value object="myObject" xpath="@myField" index="1" %>
The object can be:
"delivery" object: For email personalization, the delivery object is accessible in two ways:
For the <%@ value object="delivery" xpath="@myCustomField" %> instruction, there is another limitation for deliveries sent via mid-sourcing. The custom field @myCustomField must be added to the nms:delivery schema on both marketing and mid-sourcing platforms.
Note: for delivery parameters/variables, use the following syntax (using the delivery object):
<%@ value object="delivery" xpath="variables/var[@name='myVar']/@stringValue" %>
did you try these options?
Thanks Amit, we are currently using a method similar to option 1 however we also want to account for situations where the URL may be part of a larger block of copy/text.
For option 2 it seems like we have some barriers unless I am misunderstanding. Our delivery templates are used across multiple campaigns with a large amount of variability in the content shown. We cannot assume that one URL will be the same across campaigns so adding it as an additional script object does not seem possible.
You can create a delivery variable i.e myURLVar for this URL, and you can assign your URL value from additional data to this variable in the delivery script.
Use below for url in your delivery and this will work everywhere. you can use your parms like below if you have any.
<a heref="<%@ value object="delivery" xpath="variables/var[@name='myURLVar '']/@stringValue" %>?firstName=<%=recipeint.firstName%>" _label="custom url">my link value </a>
Thanks Amit I appreciate the time you're taking. I tried as you suggested and created a view that simply returns <%= targetData.url %> with an @include instruction in the content form, however the tracking information was not automatically appended.
You mentioned the mirror page view, this view handles the appending of the tracking information, were you suggestion my new view should do the same?