Monday, September 1, 2008

Differentiating between internal and external emails when applying an Outlook signature

BEHIND THE PRODUCTS

By Rex Weston

As a developer of HTML email signatures used in marketing communications, I'm occasionally asked whether it's possible to automatically apply different signatures to email messages sent internally (within the company or organization) versus those sent externally. Rather than continuing to answer no each time, I recently made a decision to pursue the development of this capability.

The result has been an Outlook add-on module that works in a simple, but efficient manner to differentiate between internal and external emails, and then apply one of two different signatures as appropriate. Let me begin by illustrating how this works, then I'll discuss a couple of extra features we added, and conclude with a brief explanation of the development process.

How it works

When installed, the add-on module -- called Signature-Switch -- will automatically create a signature in your signatures folder called PLACE_HOLDER. You'll need to go into Outlook's signatures settings and specify this signature as your default for new messages and for replies/forwards, as shown in Figure A. Obviously, this dialog will differ depending on which version of Outlook you're using.

FIGURE A

Set PLACE_HOLDER as your default signature. (click for larger image)

Next you'll go into the settings dialog box of the Signature-Switch module and set your parameters so that you have a different internal and external signature, as shown in Figure B.

FIGURE B

There's a different signature used depending on where it's being mailed.

These settings tell Signature-Switch which Outlook signature (already created by you using the conventional approach within Outlook) to apply to internal emails and what Outlook signature to apply to external emails.

The next setting in Signature-Switch allows you to specify one or more "internal" domains, as shown in Figure C.

FIGURE C

Domains help you determine who should be considered "internal".

In the case that the all of the recipients have email addresses using the specified domain, the email is considered internal, and the internal signature is applied. If any of the recipients (including CC, BCC) have an email address with a different domain, the email is considered external.

These three steps cover the basic setup. Let's see what happens when put to use. When an email is composed (or replied to), you'll see the PLACE_HOLDER signature, as shown in FIGURE D.

FIGURE D

Your email has some placeholder text until the signature is applied. (click for larger image)

After the SEND button is clicked, the Signature-Switch add-on evaluates the recipients and replaces the placeholder text with one of the two specified signatures. The result will be either the one shown in Figure E, for internal email or the one shown in Figure F, for external email.