Ad placements
URI Parameters
Example Implementations
Placement Code
<a href="https://[mydomain].serve.email-x.io/click/[adUnitId]?[...params]" title="Advertisement">
<img src="https://[mydomain].serve.email-x.io/view/[adUnitId]?[...params]" alt="Advertisement" width="600" height="100" border="0" />
</a>HTML Source
// Variables used with the placement code above
[mydomain]: test
[adUnitId]: 123456
[...params]: date=2019-01-27T10%3A16%3A09-06%3A00&email=%40%7Bencrypted_customer_id%7D%40&rand=9689172420<a href="https://test.serve.email-x.parameter1.com/click/123456?date=2019-01-27T10%3A16%3A09-06%3A00&email=%40%7Bencrypted_customer_id%7D%40&rand=9689172420" title="Advertisement">
<img src="https://test.serve.email-x.parameter1.com /view/123456?date=2019-01-27T10%3A16%3A09-06%3A00&email=%40%7Bencrypted_customer_id%7D%40&rand=9689172420" alt="Advertisement" width="600" height="100" border="0" />
</a><?php
function getAdUnit($adUnitId, $width, $height) {
$domain = 'https://demo.serve.email-x.io';
$template = '<a href="%s" target="_blank"><img src="%s" width="%s" height="%s" alt="Advertisement" border="0"></a>';
$params = [
'date' => date('c'),
'email' => '*|EMAIL|*',
'rand' => rand()
];
$linkUrl = sprintf('%s/click/%s?%s', $domain, $adUnitId, http_build_query($params));
$imageSrc = sprintf('%s/image/%s?%s', $domain, $adUnitId, http_build_query($params));
return sprintf($template, $linkUrl, $imageSrc);
}
echo getAdUnit('123456', 600, 100);
HTTP Request Definition
Ad Request
Path Parameters
Name
Type
Description
Query Parameters
Name
Type
Description
Last updated