[Java] Java taglibs are quite useful

My adventure down the Java road continues and it's starting to look like something. The little project I'm doing makes use of JSP pages and instead of using Servlets as the controller, I've dived into JSP taglibs.

Taglibs work somewhat like ASP.NET user controls, but they are not as powerful. Each taglib class represents a HTML-tag and you can specify different attributes for it, quite similar to user controls, but very different in implementation. The biggest problems I've had so far is working with the taglibs in my jdev 9 editor. Sometimes my taglib classes doesn't show up after using the jdev wizards, etc. I'm thinking of trying out Intellij or NetBeans instead, but I don't know how well they handle taglibs.

God what I miss DataSets when working with Java and JDBC!!

1 Comment

  • IMO, the biggest problem with taglibs is that they cannot be inherited from standard controls, such textbox.

    In this way, if you want to create a taglib which adds a small functionality to a textbox, you need to recreate it from scratch, and manually add all the standard attributes such as TabIndex, Size, Maxlength etc.

Comments have been disabled for this content.