There is no capability to add a different content type.

On Fri, Apr 18, 2014 at 1:16 PM, stephanl <stephan.l...@gmail.com> wrote:

> HTML (text/html).  For grins, I tried Plain Text (text/plain), in which
> case the base64 string was included un-escaped, but (of course) not
> recognized/rendered as image when the containing email was viewed.  In the
> configuration section of the ext-email plugin these are the only two
> options (text/html and text/plain).  If another content-type is required,
> how do I add it (UI does not show option to add addt'l content types, using
> latest jenkins and ext-email versions), and what should it be?
>
> Thx, S
>
>
>
> On Friday, April 18, 2014 3:08:05 PM UTC-5, slide wrote:
>
>> What is your content type set to in the settings?
>>
>>
>> On Fri, Apr 18, 2014 at 12:52 PM, stephanl <stepha...@gmail.com> wrote:
>>
>>> Not using templates.  Tried using
>>>
>>>
>>> <img src='data:image/png;base64, ${FILE, path="my-base64-encoded-png.b64"}'
>>> width="900" height="550"/>
>>>
>>> in the 'Default Content' section/field of the ext-email plugin.  Also
>>> tried using
>>>
>>> def reportPath = build.getWorkspace().child("my
>>> -base64-encoded-png.b64")
>>> msg.setContent("<img src='data:image/png;base64," +
>>> reportPath.readToString() + "'/>", "text/html");
>>>
>>> as pre-send script (also in the ext-email plugin, Advanced section).
>>>  From what I can tell, the html encoding occurs after the default content
>>> and pre-send scripts have been processed/executed.  Which would apply to
>>> templates as well, no?
>>>
>>> Thx, S
>>>
>>>
>>>
>>> On Friday, April 18, 2014 12:31:05 PM UTC-5, slide wrote:
>>>
>>>> Are you using a groovy or jelly template, or generating the HTML
>>>> yourself?
>>>>
>>>>
>>>> On Fri, Apr 18, 2014 at 10:20 AM, stephanl <stepha...@gmail.com> wrote:
>>>>
>>>>> Howdy,
>>>>>
>>>>> I am trying to embed a base64 img src in the body/content of an
>>>>> ext-email notification, like so:
>>>>>
>>>>> <img src='data:image/png;base64, ${FILE, path="my-base64-encoded-png.
>>>>> b64"}' width="900" height="550"/>
>>>>>
>>>>> The email I receive has all '+' characters in the included base64
>>>>> string escaped as &#43;.  I tried to set the email content in a pre-send
>>>>> groovy script, like so:
>>>>>
>>>>> def reportPath = build.getWorkspace().child("my
>>>>> -base64-encoded-png.b64")
>>>>> msg.setContent("<img src='data:image/png;base64," +
>>>>> reportPath.readToString() + "'/>", "text/html");
>>>>>
>>>>>  and still see the escapes for the '+' in the email received.  I do
>>>>> not see an option to turn off html escaping (except for a few macro 
>>>>> tokens,
>>>>> which I am not using).
>>>>>
>>>>> Any insights/advice on how I can embed a base64 image in an email
>>>>> without triggeriung automatic encoding of the base64 string?  And no,
>>>>> referencing the image by URL is not an option, unfortunately.  Last, for
>>>>> grins I have included verbatim strings in the email body/content, like
>>>>> 'A+B' and "A+B", in all cases the '+' character arrived encoded.
>>>>>
>>>>> TIA,
>>>>>
>>>>> - S
>>>>>
>>>>> --
>>>>> You received this message because you are subscribed to the Google
>>>>> Groups "Jenkins Users" group.
>>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>>> an email to jenkinsci-use...@googlegroups.com.
>>>>>
>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Website: http://earl-of-code.com
>>>>
>>>  --
>>> You received this message because you are subscribed to the Google
>>> Groups "Jenkins Users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to jenkinsci-use...@googlegroups.com.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> --
>> Website: http://earl-of-code.com
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jenkinsci-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Website: http://earl-of-code.com

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to