留言板
Send email in Freemarker Template
Hi
It is possible to send email in a freemarker template ?
Thank
It is possible to send email in a freemarker template ?
Thank
Etienne Roy,修改在9 年前。
RE: Send email in Freemarker Template
Regular Member 帖子: 114 加入日期: 13-8-8 最近的帖子
I try to use the variable serviceLocator but I always have this error Expression serviceLocator is undefined on line ...
do you know why is not work ?
example
<#assign DDLRecordLocalService = serviceLocator.findService("com.liferay.portlet.dynamicdatalists.service.DDLRecordLocalService")>
do you know why is not work ?
example
<#assign DDLRecordLocalService = serviceLocator.findService("com.liferay.portlet.dynamicdatalists.service.DDLRecordLocalService")>
The answer to your second question can be found on the following message board thread:
https://www.liferay.com/community/forums/-/message_boards/message/37572364
https://www.liferay.com/community/forums/-/message_boards/message/37572364
Olaf Kock,修改在9 年前。
RE: Send email in Freemarker Template
Liferay Legend 帖子: 6403 加入日期: 08-9-23 最近的帖子
Is it possible? Yes, see the other answers.
Should you do this? Most likely not. Freemarker Templates are view technology. Use your business layer to implement anything outside of the view realm, not templates. If this would go through my code review, I'd probably reject it unless you are implementing a very rare corner case or can really argue well for it (which I don't expect)
Should you do this? Most likely not. Freemarker Templates are view technology. Use your business layer to implement anything outside of the view realm, not templates. If this would go through my code review, I'd probably reject it unless you are implementing a very rare corner case or can really argue well for it (which I don't expect)