This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JSF and the fly likes [facelets] custom taglibrary not recognized Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "[facelets] custom taglibrary not recognized " Watch "[facelets] custom taglibrary not recognized " New topic
Author

[facelets] custom taglibrary not recognized

Jeroen Kema
Greenhorn

Joined: Feb 25, 2009
Posts: 12
Hi,

I'm building a JSF custom taglibrary where I define some template components. I've been struggling for a few days to solve a problem with my custom tags. The problem is that my custom tags are not rendered. This is what I've added to my project:

web.xml: (I've only picked the relevant code)


faces-config.xml:


gtdonline.taglib.xml:


and the costuom messages.xhtml:


When I want to use the tag library in one of my pages, I simply add the namespace as following:


When I load the page in my browser, the <gtd:messages/> tag remains as it is in the html source.

When I google for similar problems, I'm finding threads where people wrote their own renderer class and added it also to the faces-config.xml. But as far as I know, I shouldn't edit the faces-config.xml when I use the <tag><tag-name/><source/></tag> tags to tag my custom facelet templates.

Can anybody help me to fix this problem?


SCJP, SCJD
Jeroen Kema
Greenhorn

Joined: Feb 25, 2009
Posts: 12
I've fixed it already

I've added the following line to my gtdonline.taglib.xml file:



Now, the taglib is picked up during initialization and the custom tag is rendered in the browser
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: [facelets] custom taglibrary not recognized
 
Similar Threads
When trying to deploy my JSF 2.0 JSP page I get this:
Facelets custom tag not recognized ?
JSF, Facelets losing context after reload
JSF 2 : hibernate session problem in manadged beans
Can't render custom facelet component in IceFaces