Knowledge Base

How to add a placeholder-based image


You wish to add an image to a signature or disclaimer that would be different for each of the senders. The address of such an image should be made out of a static web address and information gathered from Active Directory.


The main idea here is to upload desired image files to a web server, so the images become available for everyone with internet access. You should consider putting them into a specific directory (e.g. following a specific naming pattern. For example, the name of the image file may consist of the sender's first and last name - for Howard Wilford it would be howard.wilford.jpg. You can also use any other variables that are available in Active Directory. This is important because we are going to use information pulled from AD to prepare valid references to your images on the fly.


The following method works only for online (web) images. To learn about the advantages and disadvantages of this approach, please consult this article.

When using CodeTwo Email Signatures 365, remember to upload your online images to a web server that is secured with an SSL certificate (the image URL must begin with https). You will not be able to use an image whose address begins with the http prefix.

An alternative solution would be to take advantage of conditional placeholders. With this feature, you can e.g. insert different images to an email signature depending on who the sender is. This allows you to use embedded images as well. Learn more in the editor's manual for:

If you are going to include photos of your users, consider using the {Photo} placeholder instead. Learn more in the editor's manual for:

Once you upload all images, please follow the steps below:

  1. Open Administration Panel (if you use software from the CodeTwo Exchange Rules family) or sign in at (if you use CodeTwo Email Signatures 365).
  2. Select a signature rule and edit it. The signature template editor opens.
  3. On the editor's ribbon, click Picture.
  4. Choose Online picture and provide URL to the web directory where you have stored the images. Do not include any placeholders at this moment.

Adding a picture.
Fig. 1. Adding a picture.

  1. Click OK. On the ribbon, click the Source button (or HTML source) to enter the HTML source code view.
  2. Find the IMG tag responsible for displaying your image (static part of the address). At the very end of the address, using the Placeholder → Message sender menu, add the necessary placeholders. Be advised that you have to provide the correct image file extension as well.

Adding placeholders to image address.
Fig. 2. Adding placeholders to image address.

  1. Double check if the image address is correct. Let us assume that we have a user named Howard Wilford. The path that is defined in editor should look as follows:
    <IMG src="{First name}.{Last name}.jpg">
    Once the message is processed, it will change to:
    <IMG src="">
  2. To test your signature, you can use the Signature preview button (or the Preview button) available in the editor.
Was this information useful?