The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

import-bot (20211) [Avatar] Offline
#1
[Originally posted by motobass]

I am using Jakarta project's mailer-1.1 tag and it doesn't seem to understand
the JSTL expression language? The problem I am having is with the "to"
parameter not being recognized as a valid email. It is valid, or at least
let's assume it is, it prints out correctly in a separate <c:out ...>. It has
no problem with the nested <c:out ...> in the message tag.

<mt:mail to="${initParam['site.error.email']}" >
from="${initParam['site.email.from']}"
server="${initParam['site.email.server']}"
subject="${emailSubject}">

<mt:message><c:out value="${emailMessage}"/></mt:message>
<mt:send>

The following errors occured


<mt:error id="err">
<jsp:getProperty name="err" property="error"/>

</mt:error>


</mt:send>
</mt:mail>
import-bot (20211) [Avatar] Offline
#2
Re: Jakarta's mailer-1.1 tag and EL
[Originally posted by motobass]

It works when I set a local variable to the initParam first, and then use that
in the mail tag. Hmmm.

> I am using Jakarta project's mailer-1.1 tag and it doesn't seem to understand
> the JSTL expression language? The problem I am having is with the "to"
> parameter not being recognized as a valid email. It is valid, or at least
> let's assume it is, it prints out correctly in a separate <c:out ...>. It has
> no problem with the nested <c:out ...> in the message tag.
>
> <mt:mail to="${initParam['site.error.email']}" >
> from="${initParam['site.email.from']}"
> server="${initParam['site.email.server']}"
> subject="${emailSubject}">
>
> <mt:message><c:out value="${emailMessage}"/></mt:message>
> <mt:send>
>

The following errors occured


> <mt:error id="err">
> <jsp:getProperty name="err" property="error"/>

> </mt:error>
>


> </mt:send>
> </mt:mail>
import-bot (20211) [Avatar] Offline
#3
Re: Jakarta's mailer-1.1 tag and EL
[Originally posted by bayern]

Not every project within Jakarta uses the EL; it's a JSTL-specific feature.
Once JSP 2.0 is out, you'll be able to use the expression language in all tags
-- and even in template text.

Shawn

> I am using Jakarta project's mailer-1.1 tag and it doesn't seem to understand
> the JSTL expression language? The problem I am having is with the "to"
> parameter not being recognized as a valid email. It is valid, or at least
> let's assume it is, it prints out correctly in a separate <c:out ...>. It has
> no problem with the nested <c:out ...> in the message tag.
>
> <mt:mail to="${initParam['site.error.email']}" >
> from="${initParam['site.email.from']}"
> server="${initParam['site.email.server']}"
> subject="${emailSubject}">
>
> <mt:message><c:out value="${emailMessage}"/></mt:message>
> <mt:send>
>

The following errors occured


> <mt:error id="err">
> <jsp:getProperty name="err" property="error"/>

> </mt:error>
>


> </mt:send>
> </mt:mail>