Spring mvc 我能';t在my temlate.vm(velocity)中显示我的图像
我正在尝试使用springMvc发送一封带有模板的电子邮件。我用Velocity来破坏模板。问题是中的图像无法出现在我的电子邮件中。我确信我的src是错误的! 这是我的template.vmSpring mvc 我能';t在my temlate.vm(velocity)中显示我的图像,spring-mvc,velocity,Spring Mvc,Velocity,我正在尝试使用springMvc发送一封带有模板的电子邮件。我用Velocity来破坏模板。问题是中的图像无法出现在我的电子邮件中。我确信我的src是错误的! 这是我的template.vm <html> <body> <h3>Hi ${user.login}, welcome to the Chipping Sodbury On-the-Hill message boards!</h3> <img src="fond
<html>
<body>
<h3>Hi ${user.login}, welcome to the Chipping Sodbury On-the-Hill message boards!</h3>
<img src="fond-bleu.jpg">
<div>
Your email address is <a href="mailto:${user.emailAddress}">${user.emailAddress}</a>.
</div>
</body>
</html>
您好${user.login},欢迎来到山上的齐平索德伯里留言板!
您的电子邮件地址是。
您的问题与Velocity无关,我很确定您的URL不正确:
在电子邮件中显示图像时,您必须在三种解决方案中进行选择:
- 在某处托管图像(然后图像URL将类似于
)http://myserver/...
- 将图像链接为电子邮件附件(在这种情况下,图像URL类似于
)cid:{0}
- 将图像嵌入base64(在这种情况下,图像URL类似于
)数据:image/jpeg;base64,…