This is a simple mail-tag. For now it only support simple mails and it gives direct feedback on any server connection problems which the Jakarta mailer tag does not.


Name Required Default Type Description
id true   Object/String The result variable name.
from true   Object/String The from address.
to true   Object/String The to address.
recipients true   Object/String The recipients you want to send the mail to (bcc field).
subject true   Object/String The subject of the mail.
type false text/html Object/String If you want to send it as html or plain.
charset false   Object/String The charset you want to send the mail in.
message true   Object/String The message to send.



ID-result variable contains: A boolean containing if the mail was sent successfully or not. If the mail failed to send the extra attribute “commonMailTagException” is set containing the exception.


This example sends a mail to a dummy person.

<common:mail id="success" from="" to="" recipients=";"/>
Result was: <br/>
<c:out value="${success}"/><br/>

comments powered by Disqus