Thursday, 19 September 2013

Usage of JSTL Function fn:length

Usage of JSTL Function fn:length

I am working on a defect in which by default all check-box need to be
selected, if multiple channels are used. However, currently in case of
multiple channels selects the fist channel check-box remains unselected
only
THE JSTL code is
<label data-use-main="#"
class="left-align form-inline checkbox
${fn:length(messageForm.configuredChannels) > 1 ? '' : 'hidden'}">
<form:checkbox path="emailMessageForm.useMainMessageEmail"
/>&nbsp;&nbsp;
<label>
<spring:message
code="message.use.main.content.email"></spring:message>
</label>
</label>
I m not able to understand how ${fn:length(messageForm.configuredChannels)
> 1 ? '' : 'hidden'}"> works as the checkbox checked condition depends on
it.

No comments:

Post a Comment