-
1. Re: inline image email attachment
pmuir Jan 24, 2008 1:45 PM (in response to sandy_brydon)Ok. Update to Seam 2.0.1 (I don't think anything has changed, but its worth a try). Create a JIRA issue. If you can post an example of (the email source) what it looks like now and what it should look like that would be great!
-
2. Re: inline image email attachment
sandy_brydon Jan 24, 2008 6:22 PM (in response to sandy_brydon)I have now tried with Seam 2.0.1.CR1 with the same results.
here is what is happening (i'll include all this stuff in the JIRA ticket as well):Header... Content-Type: multipart/mixed; boundary="outer-boundary" --outer-boundary Content-Type: image/gif; charset=ISO-8859-1; name=logo.gif Content-Transfer-Encoding: base64 Content-ID: <image-content-id> Content-Disposition: inline; filename=logo.gif BASE64=ENCODED=IMAGE=DATA== --outer-boundary Content-Type: multipart/alternative; boundary="inner-boundary" Content-Disposition: inline --inner-boundary Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline my plain text --inner-boundary Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline <html> <body> my html text<br /> <img src="cid:image-content-id" /> </body> </html> --inner-boundary-- --outer-boundary--
and here is how it looks like the boundaries/content types need to be set up:Header... Content-Type: multipart/alternative; boundary="outer-boundary" --outer-boundary Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit my plain text --outer-boundary Content-Type: multipart/related; boundary="inner-boundary" --inner-boundary Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit <html> <body> my html text<br /> <img src="cid:image-content-id" /> </body> </html> --inner-boundary Content-Type: image/gif; name="logo.gif" Content-Transfer-Encoding: base64 Content-ID: <image-content-id> Content-Disposition: inline; filename="logo.gif" BASE64=ENCODED=IMAGE=DATA== --inner-boundary-- --outer-boundary--
it's a bit hard to read so i'll summarize:
- it looks like Content-Disposition: inline; is on every content declaration, i don't know if this matters
- in order to have proper inline html image content it looks like both the file and the content it's being included in is required to be part of Content-Type: multipart/related; http://tools.ietf.org/html/rfc2387 -
3. Re: inline image email attachment
sandy_brydon Jan 24, 2008 6:57 PM (in response to sandy_brydon)now tested with Seam 2.0.1.CR2
-
4. Re: inline image email attachment
sandy_brydon Jan 24, 2008 7:10 PM (in response to sandy_brydon)symptoms as tested:
Mozilla Firefox
- displays the attached files, does not display inline
Apple Mail
- displays the attached files then the content of the email (images show up in both)
gmail
- shows as having attachments, prompts to display images - images display fine
hotmail
- shows as having attachments, prompts to display images - images display fine -
5. Re: inline image email attachment
pmuir Jan 25, 2008 7:08 AM (in response to sandy_brydon)Excellent info, thanks!
As with you, I'm no expert in mail encoding either (it seems a bit of a black art!) -
6. Re: inline image email attachment
sandy_brydon Jan 25, 2008 11:33 AM (in response to sandy_brydon)jira issue: http://jira.jboss.com/jira/browse/JBSEAM-2534
NOTE: above Mozilla Firefox was supposed to be Mozilla Thunderbird (apologies) -
7. Re: inline image email attachment
sandy_brydon Jan 25, 2008 5:23 PM (in response to sandy_brydon)i blame dark wizards - it's always the dark wizards...