I am sending an email to my subscribers via a triggered send. I have set up automation studio set up and the email gets triggered when I drop a file to the import folder of the FTP site. The subscriber data that I am sending over are: First Name, Last Name, Email Address, and a custom XML field that contains dynamic data specific to the subscriber. I am using an AMPScript to parse the XML field and populate an email template. The question that I have is, is it possible to include images as part of the custom XML field? The end goal is to display subscriber specific images in the email that goes out to the subscriber.
-
Where are the images hosted? If you're talking about just passing an image URL in the XML payload, then sure, that's no problem.– Adam SpriggsCommented Jan 12, 2016 at 23:19
-
I would also recommend passing the contents of the custom XML field as character data. By this I mean, wrap the contents with a <!<[CDATA[]>> tag. This way if the field contains XML or HTML content, it will not negatively impact the parsing of the API call itself.– David DevoyCommented Jan 18, 2016 at 17:50
1 Answer
While it would technically possible to encode an image into a base64 string which could be stored in XML, then displayed in HTML.
This is not a good idea for a couple reasons. First being email client support for this syntax is limited so many of your recipients wouldn't see the image. Secondly it would produce very large payloads which would be slower to transfer and slower to parse.
If the use case you are working is wanting subscriber specific images that are cooupons, then there is an offering called Live Offers which could be used: http://help.exacttarget.com/sv/documentation/exacttarget/content/live_offers/