How to align images in a messageML

By default, image alignment in Symphony is not set. If a customer wants to align an image to the left, centre or right of the page, use the div variable to align the image as desired (highlighted in red):


<div style="text-align:right">

<img src=""/>



Note: For the alignment to work successfully, the image must be placed within a div variable and not directly to the img variable.

The code above will then produce the image displayed below in Figure 1:


Figure 1 Right Aligned Image

Note: Trying to align an image using the align attribute in a message/create call will result in a 400 error with the following message 'Failed to parse MessageML: Attribute \"align\" is not allowed in \"img\"'. This is because only styling the variable via the style attribute is allowed.