< class="prominent-subhead ">

Plus signs in the Email event are converted to hexadecimal code + or into a space

This article was created in response to a support issue logged with K2. The content may include typographical errors and may be revised at any time without notice. This article is not considered official documentation for K2 software and is provided "as is" with no warranties.
This article has been archived, and/or refers to legacy products, components or features. The content in this article is offered "as is" and will no longer be updated. Archived content is provided for reference purposes only. This content does not infer that the product, component or feature is supported, or that the product, component or feature will continue to function as described herein.


When sending an email that contains HTML content using the K2 Process Email event, plus signs are converted to spaces (actual spaces, not (&#20;"). When the process is called from a SmartForm and the SmartForm passes plus signs, they are converted to "&#43;".

This article explains how to preserve the plus signs when sending HTML content that contains base64 embedded images with plus signs.


The underlying issue is that a "+" sign represents a space in base64 as it is one of the non alphanumeric characters it uses for padding.

Troubleshooting Steps

Please note: You can use https://www.base64-image.de/  to encode an image

Source: <img width="595" height="220" src="data:image/png;base64,/9j/4AAQSkZJRg+++<snip>" v:shapes="Picture_x0020_1"></font></p>

Result From K2 Process Email Event
<img width="595" height="220" src="data:image/png;base64,/9j/4AAQSkZJRg <snip>" v:shapes="Picture_x0020_1"></font></p>

Result from SmartForm
<img width="595" height="220" src="data:image/png;base64,/9j/4AAQSkZJRg&#43;&#43;&#43;<snip>" v:shapes="Picture_x0020_1"></font></p>

Keep the image URL from being distorted at runtime by first “URL encoding” the image URL prior to passing it to the process(EmailBody) as an input. The process will then URL decode it back at runtime. This way the data is preserved as is with the + signs in the image URL. See the example below: 

INPUT VALUE(parameter):




OUTPUT VALUE(process runtime):
<font><p>hello<BR><img width="595" height="220" src="data:image/png;base64,/9j/4AAQSkZJRg+++" v:shapes="Picture_x0020_1"></font></p>