Bangaram
Bangaram

Reputation: 51

Is it possible to access a bean variable in jsf?

I want to access a string variable from a managed bean and compare it another value and thereby render a table only if they are equal.

Can anyone help me on this?

Upvotes: 1

Views: 325

Answers (1)

digitaljoel
digitaljoel

Reputation: 26574

put the table in a ui:panel and then in the rendered attribute of the panel put some EL, like

rendered="#{mybean.myProperty eq 'mystring'}"

Upvotes: 4

Related Questions