Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Enabling and disabling a selectonemenu and textarea in jsf

 
vibhas karn
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all i want to make a very simple application in which on selecting the checkbox only the selectonemenu appears and also the text are appears i same page where i have the select checkbox is present i have tried doing it but getting error can any body help me in this code or give me some better code to do so. Here is my code


index.jsp

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@





@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@


and my bean class is







the error which i am getting is:-


index.jsp:33:29: The deferred EL expression is not allowed since deferredSyntaxAllowedAsLiteral is false.
disabled="#{EnableDisable.disable1}" </h:selectOneMenu>/>
^-----------------------^
index.jsp:33:29: The deferred EL expression is not allowed since deferredSyntaxAllowedAsLiteral is false.
disabled="#{EnableDisable.disable1}" </h:selectOneMenu>/>
^-----------------------^

at weblogic.servlet.jsp.JavelinxJSPStub.compilePage(JavelinxJSPStub.java:328)
at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:237)
at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:182)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:235)
at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:408)
Truncated. see log file for complete stacktrace


thanks in advance
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65225
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please be sure to ask JSF questions in the JSF forum. I have moved this post there for you.
 
Kavita Tipnis
Ranch Hand
Posts: 177
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
From what I get from your post , take a look at the 'rendered' property of your selectOnemenu if you want it to appear/disappear.
Please do not mix plain old html with jsf, you can do use UIPanelGrid to create an html table
 
Martin Lopez Ochoteco
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Vibhas, I think you are asking something like what's explained on this post http://www.coderanch.com/t/414509/JSF/java/rich-comboBox-valueChangeListener-not-working . You'll have to use a valueChangeListener .

PS: Kavita, why do you say it's not advisable to mix old html with jsf? I'm doing this on my app with a html table.. (reply to me in private if you wish)
 
Kavita Tipnis
Ranch Hand
Posts: 177
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Martin Lopez Ochoteco wrote:Hi Vibhas, I think you are asking something like what's explained on this post http://www.coderanch.com/t/414509/JSF/java/rich-comboBox-valueChangeListener-not-working . You'll have to use a valueChangeListener .

PS: Kavita, why do you say it's not advisable to mix old html with jsf? I'm doing this on my app with a html table.. (reply to me in private if you wish)


Take a look at this post Mixing Html and JSF

Also take a look at facelets which can take care of already existing html in the jsf page.

I found a blog which explains the gotchas of mixing plain html with jsf
Mixing Html and JSF gotchas
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic