File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSF and the fly likes Why are my JSTL tags not being interpreted in my JSF page? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Java » JSF
Reply Bookmark "Why are my JSTL tags not being interpreted in my JSF page?" Watch "Why are my JSTL tags not being interpreted in my JSF page?" New topic
Author

Why are my JSTL tags not being interpreted in my JSF page?

Jehan Jaleel
Ranch Hand

Joined: Apr 30, 2002
Posts: 181
Hi all,

I have a JSF page (.xhtml extension). In it I have the following..



But this JSTL code is not being interpreted. When the page loads it shows both Invoice and Credit Memo and I do view source I see "<c:choose" in my source. I made sure JSTL 1.2 jar is there in my WEB INF/lib.

What else could be missing? Is JSTL not supported on xhtml pages?

Thanks.>
Seetharaman Venkatasamy
Ranch Hand

Joined: Jan 28, 2008
Posts: 5575

Jehan Jaleel wrote:Is JSTL not supported on xhtml pages?

Dont know.

but, I dont see JSTL taglib directory definition.

SetupJstlForJsp2
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 56528
    
  14

Please be sure to ask JSF questions in the JSF forum. I have moved this post there for you.


[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
Jehan Jaleel
Ranch Hand

Joined: Apr 30, 2002
Posts: 181
Seetharaman Venkatasamy wrote:
Jehan Jaleel wrote:Is JSTL not supported on xhtml pages?

Dont know.

but, I dont see JSTL taglib directory definition.

SetupJstlForJsp2


Does this not do the trick for JSTL taglib directory..

<ui:composition
xmlns:c="http://java.sun.com/jstl/core">
Jehan Jaleel
Ranch Hand

Joined: Apr 30, 2002
Posts: 181
I figuered it out. Seems JSTL tags do not work inside JSF datatable. When I changed to the following it worked...
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 14568
    
    7

There is practically no reason for ever using JSTL in JSF pages, because the same functions are available via native JSF tags - which, unlike JSTL - are aware of the JSF environment.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Why are my JSTL tags not being interpreted in my JSF page?
 
Similar Threads
Can multiple conditions be checked using JSTL?
Issue with jstl + facelets
Nesting JSTL Tags
jsf-html with jstl-core
[Facelet & JSF Security] What do you think of this?