Knowledge Base

How to use placeholders with links

Problem:

You would like to use placeholders with hyperlinks, for example to turn another placeholder into a link or to act as a variable part of a link.

Solution:

With CodeTwo Email Signatures 365, you can use placeholders with links in a number of ways. If you properly populate Entra ID (Azure AD) attributes with a personalized hyperlink or a variable part of a hyperlink for each user, users’ signatures will be automatically updated with personalized links once an email is sent. Let’s have a look at the two above mentioned scenarios:

Use placeholder with a web link to turn another placeholder into a linked element

You want to link a user’s photo in a signature to the intranet profile of a specific user, based on the URL stored as CustomAttribute1 in our Attributes manager or the Microsoft 365 admin center. That way, when an email recipient clicks the user’s photo, they will be taken to the sender’s individual profile, e.g. to learn more about them, see their projects and so on. Follow the steps below to learn how to do so:

Tips

Before you proceed, make sure you have properly configured the value (website or resource address) for the attribute of your choice. To avoid any problems, use the full address with https:// prefix and the www part as well.

Bear also in mind that if you choose to use the Microsoft 365 admin center, it may take several minutes for Entra ID (Azure AD) attributes to update, so it’s best to configure the attribute for your users before proceeding with the instructions below. Even better, you can sign in at attributes.codetwo.com (Attributes manager) and edit attributes there to enjoy easier experience with instant updates.

Instead of using a custom attribute, you can choose any standard attribute, e.g. {Web page}, that can store a string value (URL). Also, with CodeTwo’s Attributes manager, you can quickly create custom attributes to use them the way you want. Learn more

  1. Sign in to the signature management app.
  2. Navigate to the signature you want to edit (Fig. 1.).

Opening the signature template for editing.
Fig. 1. Opening the signature template for editing.

  1. On the editor’s ribbon, click the HTML source button.
  2. In the HTML source code view window, locate the placeholder you want to turn into a link (e.g. {Photo 1}).
  3. Next, add the HTML hyperlink code around the {Photo 1} placeholder to make it look like this:
    <a href="">{Photo 1}</a>

    and place the cursor between the quotation marks, as shown in Fig. 2.

Making a placeholder into a link in the HTML source code of the signature template.
Fig. 2. Making a placeholder into a link in the HTML source code of the signature template.

  1. Now, click the Placeholder button and select the placeholder which you previously configured to store a unique website or resource address for each of your users. In our example, it is {CustomAttribute1} (Fig. 3.).

Choosing a placeholder which will be used to create a link.
Fig. 3. Choosing a placeholder which will be used to create a link.

  1. The placeholder should be inserted between the quotation marks, exactly where you previously placed your cursor (Fig. 4.).

The final configuration – the {Photo} placeholder is linked to the URL stored in the {CustomAttribute1} placeholder.
Fig. 4. The final configuration – the {Photo} placeholder is linked to the URL stored in the {CustomAttribute1} placeholder.

  1. Click Apply & Close to close the HTML source code view.
  2. Now, you can test the signature for different users in your organization by using the Signature preview feature (learn more). If everything’s OK, you should see the pointer cursor when you hover mouse over the linked user photo. The user-specific link should be also displayed at the bottom of your browser window (Fig. 5.).

    Important

    Our software synchronizes your Entra ID (Azure AD) attributes every 20 minutes. If you have just updated your users’ attribute(s) values in the Microsoft 365 admin center, the changes may not be immediately reflected in your signature, and clicking the photo might take you to a wrong website or resource address. If that’s the case, try updating Azure AD cache manually in CodeTwo Admin Panel. Learn more

The user photo in a signature in now linked to the sender’s individual intranet profile.
Fig. 5. The user photo in a signature in now linked to the sender’s individual intranet profile.

  1. If everything works as intended, close the Email preview window and click Apply & Close to close the editor. Once you’re back to the signature management app, click Save & Publish for your changes to take effect.

Use a placeholder as a variable part of a link

You want to use a link to a LinkedIn profile in your signature. Each LinkedIn profile link consists of the fixed part (https://www.linkedin.com/in/) and the individual part that comes directly after (e.g. megan-bowen-33xx56444/). You can add that individual part to an attribute (e.g. CustomAttribute2) in our Attributes manager or the Microsoft 365 admin center (see how to do this) for each of your users and then use the {CustomAttribute2} placeholder to add a personalized LinkedIn profile link to your signature template. Follow the steps below to learn how to do so:

Tips

Bear in mind that if you choose to use the Microsoft 365 admin center, it may take several minutes for Entra ID (Azure AD) attributes to update, so it’s best to configure the attribute for your users before proceeding with the instructions below. Even better, you can sign in at attributes.codetwo.com (Attributes manager) and edit attributes there to enjoy easier experience with instant updates.

Instead of using a custom attribute, you can choose any standard attribute, e.g. {Web page}, that can store a string value (the variable part of LinkedIn profile link). Also, with CodeTwo’s Attributes manager, you can quickly create custom attributes to use them the way you want. Learn more

  1. Sign in to the signature management app.
  2. Navigate to the signature you want to edit, as shown in Fig. 1.
  3. Once in the editor, put the cursor in the place where you want to add the LinkedIn link and click the Social link button (Fig. 6.).

Adding a social link to the signature.
Fig. 6. Adding a social link to the signature.

  1. In the window that opens, choose LinkedIn from the Media dropdown list – this will apply the predefined LinkedIn social link settings.

    Info

    If you cannot find your social media platform on the Media list, choose Custom and configure all the settings according to your needs.

  2. Next, (if necessary) edit the fixed part of the URL, so that is has the following form: https://www.linkedin.com/in/, place the cursor immediately after it and use the Placeholder button to choose the attribute you previously used in the Microsoft 365 admin center to store the variable part of the LinkedIn link, e.g. {CustomAttribute2} (Fig. 7.).

Choosing a placeholder which will be used to create an individual LinkedIn profile URL.
Fig. 7. Choosing a placeholder which will be used to create an individual LinkedIn profile URL.

  1. Configure other settings such as label text or icon. The sample configuration should look as shown in Fig. 8. Click OK to insert your link into the template.

Sample configuration of a LinkedIn profile link.
Fig. 8. Sample configuration of a LinkedIn profile link.

  1. Now, you can test the LinkedIn profile link for different users in your organization by using the Signature preview feature (learn more). If everything’s OK, you should see the user-specific LinkedIn link at the bottom of your browser window when you hover your mouse pointer over the newly-added social link (Fig. 9.).

    Important

    Our software synchronizes your Entra ID (Azure AD) attributes every 20 minutes. If you have just updated your users’ attribute(s) values in the Microsoft 365 admin center, the changes may not be immediately reflected in your signature, and you may see incorrect link. If that’s the case, try updating Azure AD cache manually in CodeTwo Admin Panel. Learn more

The complete link: fixed part + variable part fetched from Entra ID (Azure AD) custom placeholder #2 for Megan Bowen.
Fig. 9. The complete link: fixed part + variable part fetched from Entra ID (Azure AD) custom placeholder #2 for Megan Bowen.

  1. If everything works as intended, close the Email preview window and click Apply & Close to close the editor. Finally, apply the changes to email signatures in your organization by clicking Save & Publish.

    Tip

    With our editor, the use of placeholders is not limited to social links only. You can use them with virtually any link whose part or parts change from user to user. To do it, first populate your users’ attributes with appropriate values in the Microsoft 365 admin center. Next, edit the HTML code of your signature, which you can access by clicking the HTML source button on the editor’s ribbon, and change the link values by using placeholders, as shown in Fig. 10. Check out this article for more examples

    More examples of links with a placeholder.
    Fig. 10. More examples of links with a placeholder.

Was this information useful?