| This Chapter | |
| - | Chapter 9: The Logic Tag Library |
| - | The Value Comparison Tags |
| - | The Substring Matching Tags |
| - | The Presentation Location Tags |
| - | The Collection Utility Tag |
| - | Summary |
The Logic Tag Library is one of Struts’ core tag libraries and used to be indispensable. However, it became redundant after the release of JSTL. You are recommended to use JSTL because it is the standard and more powerful than the Logic Tag Library. This chapter is here because the Logic Tag Library is still widely in use and those wanting to migrate to JSTL may need this chapter as a reference.
The tags in the Logic Tag Library fall into the following categories.
All the tags are discussed in this chapter in the following sections.
Note
To reference the Logic Tag Library’s tags indirectly, you need the struts-logic.tld file in your WEB-INF directory and the following taglib element in your web.xml file.
<taglib>
<taglib-uri>/tags/struts-logic</taglib-uri>
<taglib-location>/WEB-INF/struts-logic.tld</taglib-location>
</taglib>
Note
The app09a application provides examples of how to use the tags in the Logic Tag Library. You can run it by using this URL.
http://localhost:8080/app09a/testLogic.do