ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Email with embedded images

Post new topic  Reply to topic
 Email with embedded images « View previous topic :: View next topic » 
Author Message
nelson
PostPosted: Sat Nov 15, 2014 10:04 am    Post subject: Email with embedded images Reply with quote

Partisan

Joined: 02 Oct 2012
Posts: 313

Hi All,

I'm trying to send an email with an embedded image (not referenced by an URL).

Looking at the EmailOutput node I only see these properties:

Code:
Destination.Email.Attachment.Content
Destination.Email.Attachment.ContentType
Destination.Email.Attachment.ContentName
Destination.Email.Attachment.ContentEncoding


Digging a little I found that we need "inline" disposition type to use embedded images within the email:

Code:
disposition-type := "inline"


Also, there are other fields that I couldn't find as a configurable values by the node.

This is an extract of the message that should be created to send to the mail server (not an expert on email format, but I think this is something like the node is generating and sending to the mail server):

Code:

...
<p style="margin: 0; padding: 0"><img src="cid:083.gif" alt="" /></p>

---------------...B128803765634796
Content-type: image/gif; name="083.gif"
Content-ID: <083.gif>
X-Attachment-Id: 083.gif
Content-Disposition: inline; filename="083.gif"
Content-transfer-encoding: base64
...


I suppose disposition-type := "attachment" is generated automatically by IIB, because it is not a configurable property.

I would expect to fill something like this:

Code:
Destination.Email.Inline.Content
Destination.Email.Inline.ContentType
Destination.Email.Inline.ContentName
Destination.Email.Inline.ContentEncoding
Destination.Email.Inline.ContentID


Is this a limitation of IIB or am I missing something? embedded images are not allowed?

Thanks a lot for your help.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Mon Nov 17, 2014 5:41 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

Well, you could go to the trouble to build a full MIME tree yourself.

You might also play around with adding disposition to the Destination.Email.Attachment subtree.

I'm not saying it would be honored or used or allowed. I'm saying I'd probably poke at it and see, myself.
Back to top
View user's profile Send private message
nelson
PostPosted: Mon Nov 17, 2014 6:59 am    Post subject: Reply with quote

Partisan

Joined: 02 Oct 2012
Posts: 313

mqjeff wrote:
Well, you could go to the trouble to build a full MIME tree yourself.


Thanks mqjeff, by build a full MIME tree you mean to send manually the email through a JCN for example, instead of using the EmailOutput Node? because before using this node we must set this environment destination variables (map the MIME parts to the EmailOutput Node "format").
Back to top
View user's profile Send private message
mqjeff
PostPosted: Mon Nov 17, 2014 7:00 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

No. I mean populate the logical message tree under OutputRoot.MIME.
Back to top
View user's profile Send private message
nelson
PostPosted: Mon Nov 17, 2014 7:11 am    Post subject: Reply with quote

Partisan

Joined: 02 Oct 2012
Posts: 313

Ohh I understand... In fact, I'm following the IIB Sample, but they put a JCN before the EmailOutput Node to parse the MIME tree and build the EmailOutputHeader and the OutputLocalEnvironment.Destination tree; the EmailOutput Node does not "consume" MIME format...
Back to top
View user's profile Send private message
mqjeff
PostPosted: Mon Nov 17, 2014 7:15 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

The EmailOutput node should serialize a message tree under the MIME parser in the same way it serializes a message tree under any other parser.

You don't need to use a JCN to populate a MIME parser tree.
Back to top
View user's profile Send private message
smdavies99
PostPosted: Mon Nov 17, 2014 10:24 am    Post subject: Reply with quote

Jedi Council

Joined: 10 Feb 2003
Posts: 6076
Location: Somewhere over the Rainbow this side of Never-never land.

The trick here (from my own experimenting) is to modify the sample flow and put two Trace nodes before the email output node.

Then setup one to display

$Root

and the other

$LocalEnvironment

Then run the test and capture the message trees.

Take that information and then get your code to give exactly the same tree structures.

I did this for an email output flow some years ago. IT took me 3-4 hours and then I had a working flow.
_________________
WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995

Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Email with embedded images
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.