Results 1 to 3 of 3

Thread: General question about using taglibraries with spring

  1. #1
    Join Date
    Aug 2004
    Posts
    14

    Default General question about using taglibraries with spring

    Hi,

    Not sure if it's right post, at least it isn't about support .. I would like to know opinion from other spring's users.
    What you guys are using for outputting HTML in JSP? I'm using spring's MVC and write things using JSTL tags. But it isn't intended for formatting to HTML. I need way how to easily and without duplication output HTML elements like tables, forms, listboxes, buttons, input fields etc. Ideally should be easy to use and flexible enough.
    What is good library for that, is it JavaServer Faces? I read that it is integrated with latest spring, quite important.
    I guess XSLT isn't for me right now. Also form and input validation is quite needed. Spring has one or should I use some other?
    I'm using latest Tomcat.

    Second question, what to use for removing duplication in JSTL code? I have same tag library statements in multiple places, like <core:forEach >generate something ... </core:foreEach>
    I hate duplication In java I would extract function. In JSTL I discovered I can make new tagfile which contains these statements but this seems not so good idea.

    thanks

  2. #2
    Join Date
    Aug 2004
    Location
    Amsterdam, Netherlands
    Posts
    450

    Default

    If you want to have reusable elements you can use to generate HTML in your JSPs, you should have a look at tagfile, part of the JSP 2.0 spec (your Tomcat - I assume it's 5.0 - supports it). There's a pretty decent article on JSP 2.0 at OnJava: http://www.onjava.com/pub/a/onjava/2003/11/05/jsp.html.

    Why doesn't that sound like a good idea to you?

  3. #3
    Join Date
    Aug 2004
    Posts
    14

    Default

    ok, I wrongly thought that for each tag file I must create different prefix. Seems that using tagfiles is ok, thanks!
    Hope somebody would answer also my first question. I have used freemarker little before, seemed ok, I know some people who don't suggest using velocity or struts.

Similar Threads

  1. Replies: 3
    Last Post: Sep 29th, 2005, 03:30 PM
  2. A Spring Class Loader?
    By azzoti in forum Architecture
    Replies: 8
    Last Post: May 7th, 2005, 04:02 AM
  3. Spring debugging question : IoC
    By etienno in forum Architecture
    Replies: 7
    Last Post: Apr 13th, 2005, 08:26 AM
  4. Replies: 5
    Last Post: Mar 14th, 2005, 10:18 AM
  5. Replies: 14
    Last Post: Feb 21st, 2005, 05:41 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •