• Post Reply Bookmark Topic Watch Topic
  • New Topic

EL not evaluated  RSS feed

 
krishan go
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
the following code line is not being evaluated


<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
<h: outputText value="#{UserBean.userName}" />to JSF 1.2 World!
i have stored the bean value as "welcome"
i should get the output as welcome to jsf 1.2 world

but i am simply getting
#{UserBean.userName} to JSF 1.2 World!

what am i doing wrong

Please help
Krishan

 
Tim McGuire
Ranch Hand
Posts: 820
IntelliJ IDE Tomcat Server VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is usually because the web.xml specifies the wrong servlet container. What does your web.xml say?
 
Tim Holloway
Bartender
Posts: 18715
71
Android Eclipse IDE Linux
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tim McGuire wrote:This is usually because the web.xml specifies the wrong servlet container. What does your web.xml say?


:confused:

I don't think the term "servlet container" really applies here - that's more about the application server program itself. But this particular problem of JSPs not evaluating EL is common for people who don't realize the difference between the jsp file (resource) and the web URL that consumes that resource, submitting a URL that pulls the file directly instead of routing it via the FacesServlet. And yes, web.xml controls how URLs are routed.

Someone else just asked the same question, so I recommend searching this forum for the detailed answer given there.
 
Tim McGuire
Ranch Hand
Posts: 820
IntelliJ IDE Tomcat Server VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't know why I wrote servlet container. I meant that the web.xml specifies the wrong version in the web-app tag. That was my problem on at least one past occasion.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!