MFMailComposerViewController在其邮件正文中显示URL作为纯文本而不是可点击链接。无论如何,我可以做到这一点?MFMailComposerViewController无法识别URL为链接
0
A
回答
2
设置为HTML,使用<a href="link">The link</a>
使用– setMessageBody:isHTML:
。平原就像它被称为平原一样。
1
MFMailComposeViewController *composer = [[MFMailComposeViewController alloc] init];
composer.mailComposeDelegate = self;
[composer setMessageBody:message isHTML:YES];
NSMutableString *body = [NSMutableString string];
[body appendString:@"<h1>Hello User!</h1>\n"];
[body appendString:@"<a href=\"http://www.mysite.com/path/to/link\">Click Me!</a>\n"];
[composer setMessageBody:body isHTML:YES];
希望这适用于你。快乐编码:)
1
是的,它是可能的,你能做到这样:
MFMailComposeViewController *composer = [[MFMailComposeViewController alloc] init]; composer.mailComposeDelegate = self;
[composer setSubject:subject];
[composer setMessageBody:message isHTML:YES];
//Message is just a NSString with HTML Content and you can have all the HTML Contents in it.
相关问题
- 1. 无法识别链接类
- 2. Mysqli_real_escape_string无法识别链接
- 3. facebook链接无法识别为gif
- 4. 克++链接程序无法识别-Bstatic
- 5. GNU链接:文件无法识别
- 6. Python无法识别软链接变更
- 7. rails无法识别sym链接目录
- 8. 缩短URL无法识别
- 9. readHTMLTable无法识别URL
- 10. HttpGet无法识别url
- 11. 文件格式无法识别;视为链接器脚本
- 12. 为什么我的链接列表类型无法识别?
- 13. 接口无法识别
- 14. Perl -e文件测试无法识别无效链接
- 15. 使用NSURL无法识别URL变量
- 16. UIWebView无法识别的URL地址
- 17. 无法识别Web服务URL更改
- 18. #标签的URL请求无法识别
- 19. Contenteditable /无法识别$ _GET变量从URL
- 20. UI路由器无法识别URL
- 21. PDFBox不识别链接
- 22. bash如何识别链接?
- 23. c中的链接识别#
- 24. 识别h:outputText中的链接
- 25. IIS在通过Word文件链接时无法识别cookie
- 26. Android上的whatsapp无法识别完整网址链接
- 27. QnA Maker无法识别使用标记语言的链接
- 28. normalizeResponse无法识别嵌套关系之间的链接
- 29. React Native - iOS无法识别分支链接
- 30. on无法识别添加的链接元素
添加乌尔行代码在乌尔问题 – Saad