B bluedude Well-Known Member Licensed User Longtime User Oct 9, 2014 #1 Hi, I'm trying to use the email intent with an html page which has server side images and one attachment. The HTML looks like this: <!DOCTYPE html> <html> <body> <img src="<imglink>" alt="Product"> </body> </html> and the code: Dim e As Email e.Subject = "Test" e.Body = html e.Attachments.Initialize e.Attachments.Add(File.DirRootExternal & "/pictures/QRcode.png") 'start html email StartActivity(e.GetHtmlIntent) The attachment works but my img src stuff in the html not. When I start the intent I see "obj" in the message while i'm pointing to server side images in the html. Any suggestions? I'm replacing the <imglink> with my server image URL's.
Hi, I'm trying to use the email intent with an html page which has server side images and one attachment. The HTML looks like this: <!DOCTYPE html> <html> <body> <img src="<imglink>" alt="Product"> </body> </html> and the code: Dim e As Email e.Subject = "Test" e.Body = html e.Attachments.Initialize e.Attachments.Add(File.DirRootExternal & "/pictures/QRcode.png") 'start html email StartActivity(e.GetHtmlIntent) The attachment works but my img src stuff in the html not. When I start the intent I see "obj" in the message while i'm pointing to server side images in the html. Any suggestions? I'm replacing the <imglink> with my server image URL's.
ivan.tellez Active Member Licensed User Longtime User Oct 9, 2014 #2 Try to set the MIME type to "message/rfc822" Upvote 0
B bluedude Well-Known Member Licensed User Longtime User Oct 9, 2014 #3 You cannot set mime types with the email intent. Where should I put it? Upvote 0
P Phil Griffiths New Member Licensed User Longtime User Feb 1, 2016 #4 I am trying to do something similar I would like to give the attachment a content-id so that I can reference the attachment in HTML in the email text For example: in B4A Dim email As Email email.ContentMIMEType = ""message/rfc822" Dim Attachment As EmailAttachment Attachment.Filename = "picture.jpg" Attachment.ContentId = "att1" email.attachment.add(Attachment) In HTML email message string <!DOCTYPE html> < html> < body> < img src="cid:att1" alt="Product"> < /body> < /html> Please can anyone give suggestions or point me at java code for Email so that I can work out how to implement this in a new or amended library? many thanks Upvote 0
I am trying to do something similar I would like to give the attachment a content-id so that I can reference the attachment in HTML in the email text For example: in B4A Dim email As Email email.ContentMIMEType = ""message/rfc822" Dim Attachment As EmailAttachment Attachment.Filename = "picture.jpg" Attachment.ContentId = "att1" email.attachment.add(Attachment) In HTML email message string <!DOCTYPE html> < html> < body> < img src="cid:att1" alt="Product"> < /body> < /html> Please can anyone give suggestions or point me at java code for Email so that I can work out how to implement this in a new or amended library? many thanks