I'm currently building an app that has Email sending capabilities. I'm trying to send an Email with the relevant information and includes a link to the original post that is being sent. the original post is created as an HTML code segment, so I have to send the Email as an HTML. i create the Email dialog like this:
var mail = Ti.UI.createEmailDialog({ subject:'FW:'+post.desc, html:true, messageBody: '<br><br><a href="http://www.XXXXXXXX.com/index.php?tid='+post.id+'" target="_blank">view original post</a><br><br><b style="font-size:1.5em;font-family:Arial">'+post.desc+'</b><br><br><i>'+metaData.text.toString().replace(/\n/g,'<br>')+' </i><br><br>'+post.htmlData }); Ti.API.debug(mail.messageBody) mail.open();when I ran the app on my device, I got the option of sending via "mail" or via "Gmail". when sent via "mail", all the link tabs and <b> and <i> were ignored and striped so the Email didn't include them. however, the "Gmail" option left everything as suppose to.
any thoughts?
1 Answer
Accepted Answer
Well, unfortunately, the Android's default Mail App cannot display html mail contents as it is explained here.
This is a limitation from the mail app itself and has nothing to do with your code. (You can try to send a html message from your PC and read it with the default app. You will experience the same problem)
You can take little comfort though that unlike iOS. Most people don't use the default mail app on Android (this is only from my experience, so it can differ). People use the gmail or the new hotmail app in most cases.
Your Answer
Think you can help? Login to answer this question!