Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JSTL test condition not evaluating properly?  RSS feed

 
brannan nu
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
im using tomcat 6 and jstl 1.2

My backing bean has a variable that looks something like this:


then the correct getters/setters.

within filesDTO i have a boolean:


now, within my jsp page i have an icefaces datatable that looks something like:


i have trimmed out a little bit but this is the main part of my problem. It always evaluates to false, even if the actual backingBean.files.active value is true.
if i do a then i get "true" so i know the value is set

if i make a boolean in my backing bean and make the getter/setters and put that in the when case, it works just fine.
anyone have any suggestions?

Thanks!
 
Tim Holloway
Bartender
Posts: 18531
61
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the JavaRanch, Brannan!

JSTL does not mix well with JSF and should be avoided. There's also no need for JSTL, since JSF can do everything that JSTL could anyway except for some things that are not good MVC to begin with, like coding business logic on the web page itself.

The JSF solution to your problem is actually a lot simpler than JSTL, in any case:



Note also that JSF uses the "#" EL notation instead of the "$" in order to support both read-only and read-write references.
 
brannan nu
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
that worked perfectly, you sir, are awesome
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!