How to remove spacing between e-mail body and signature
While composing a signature you may encounter a problem where the spacing between e-mail body and signature is too wide. This may be caused by incorrect signature design or unnecessary tags used in the HTML code of the signature.
Here are the most common reasons to such a behavior:
- There may be an empty paragraph tag (<P>)on top of your signature template. It does not add any content to the signature other than an empty space. An empty paragraph usually looks like this: <P> </P>.
- When adding an image or a table on top of your signature you may add a too large top margin for the added object. To make sure that does not happen you can edit the MARGIN-TOP attribute to be "0". An example of such code would be: <IMG style="MARGIN-TOP: 0" title="example" alt="[image]" src="http://imageserver.com/image.png">
- Similarly to MARGIN you may also need to add PADDING. The padding clears an area around the content (inside the border) of an element. Therefore if you create an object with assigned PADDING you may experience too wide top spacing between e-mail body and signature. In such a case it is best to assign PADDING-TOP in the value 0. For example: <TABLE style="PADDING-TOP: 0; PADDING-RIGHT: 3pt; PADDING-LEFT: 3pt">
- It is also possible to set the line height for each line created in your signature, this is done by using the CSS style LINE-HEIGHT. However, abusing this style may cause unnecessary spacing.
- Consider the difference in line breaking. Instead of hitting Enter key (generating new paragraph) or appending additional table cell, you may simply use Shift+Enter shortcut that only breaks the current line.
- The paragraphs generated in HTML code may be displayed differently depending on the application used. For example in OWA application all paragraphs are shown without any margins, when in desktop Outlook the spacing is pretty visible. To avoid such problem you may add MARGIN and PADDING attributes (like in points 2 and 3).
- You might want to implement a scenario where your signature is divided into two separate rules. For instance: one of the rules contains a signature and the second one contains only a disclaimer. Once the both templates are inserted into your message you notice that there is a gap between them. This can be resolved by adding the style MARGIN: 0 for any element after the <BODY> tag in the second template. It would look like this:
<P style="MARGIN: 0">...</P>
- When creating a template in some third party tool it may add some tags that are not supported by our software nor even valid according to W3C standards. Importing the code created in such a tool to the Template Editor of any of CodeTwo products may cause the template to be displayed incorrectly. One of the problems can also be some additional spacing. For that reason we always recommend designing signatures directly in our built-in Template Editor.
- If you are experiencing unnecessary spacing when sending e-mails from iPhones or iPads please check if your iOS signature does not have any spacing in it. To do so please access the device Settings, navigate to Mail, Contacts, Calendars:
|Related products:||CodeTwo Email Signatures for Email Clients, CodeTwo Exchange Rules 2007 3.x, 4.x, CodeTwo Exchange Rules 2010 2.x, 3.x, CodeTwo Exchange Rules 2013 1.x, 2.x, CodeTwo Exchange Rules 2016 1.x, CodeTwo Exchange Rules 2019 1.x, CodeTwo Exchange Rules Pro 1.x, 2.x|