Thank you.
Can you please tell me how can i put a 'AND' condition in
the test
attribute in <c:when>?
For example, I would like to do this:
<c:when test="#{ (fn:length(firstList)> 4)
&& (fn:length(secondList)> 5)}">
i get this error message:
The entity name must immediately follow the '&' in the
entity reference.
On 11/23/06, Harry Co <harryco.magic gmail.com> wrote:
> You may also use ternary operator if for example your
simply want to toggle
> the displayed value
> like this
>
>
> <h:outputText value="#{myBean.value=='first' ?
'value is 1':
> (myBean.value=='second' ? 'value is 2' : 'unknown
value' ) }" />
>
>
> HTH,
>
> Harry
>
> 2006/11/22, ying lcs <yinglcs gmail.com>:
> >
> > Hi,
> >
> > Can you please tell me how can i do a if-then-else
logic in facelet?
> > From the documentation, it said facelet only
support "if"?
> >
> > Table 3.2. <c:if/>
> > Attribute Required? Description
Example
> > var false An optional expression variable to
store the result of
> > evaluating the 'test' attribute. result
> > test true A required expression that
evaluates to a boolean for
> > deciding if the body of this tag is included in
tree creation. Note,
> > an expression evaluating to null is also false.
#{user.roles['admin']}
> >
> > Thanks for any suggestion.
> >
> >
>
------------------------------------------------------------
---------
> > To unsubscribe, e-mail:
> users-unsubscribe facelets.dev.java.net
> > For additional commands, e-mail:
> users-help facelets.dev.java.net
> >
> >
>
>
------------------------------------------------------------
---------
To unsubscribe, e-mail: users-unsubscribe facelets.dev.java.net
For additional commands, e-mail: users-help facelets.dev.java.net
|