> For the complete documentation index, see [llms.txt](https://potoyang.gitbook.io/spring-in-action-v4/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://potoyang.gitbook.io/spring-in-action-v4/untitled-12/untitled-2.md).

# 19.2　构建丰富内容的 Email 消息

对于简单的事情来讲，纯文本的 Email 消息是比较合适的，比如邀请朋友去观看比赛。但是，如果你要发送照片或文档的话，这种方式就不那么理想了。如果作为市场推广 Email 的话，它也无法吸引接收者的注意。

幸好，Spring 的 Email 功能并不局限于纯文本的 Email。我们可以添加附件，甚至可以使用 HTML 来美化消息体的内容。让我们首先从基本的添加附件开始，然后更进一步，借助 HTML 使我们的 Email 消息更加美观。
