File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes Why are tag files used Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Why are tag files used" Watch "Why are tag files used" New topic
Author

Why are tag files used

James Winfrey
Ranch Hand

Joined: Jan 04, 2009
Posts: 60
Hi Guys

Why do we use tag files instead of jsp:include and c:import?

Thanks
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61092
    
  66

There could be many reasons, but for me it boils down to one word: parameterization.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

They're kind of different things, too: tags are generally intended to encapsulate behavior, can do things to their bodies, etc. Includes are primarily focused on presentation only, don't "do" anything, and so on.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Why are tag files used