JSP Directive tutorial for Java Beginners

Directive is a type of Statement which can be used to give instruction to container about doing something special at @ page transalation time.

Directive can be divided in three types

  • Page
  • Include
  • Taglib

Page Directive

Syntax of Page Directive

 

Uses of Page Directive

Import Package

Page directive can be used to import single or double package.

Import Single Package

 

Import Multiple Package 

 

Taglib Directive

This directive is used to define tag libraries available to JSP.

Syntax of taglib Directive

 Uses of taglib Directive

taglib directive can be useful in case of Custom tags.

About the author

J Singh

Main brain behind this blog/QnA site. She has written all these article as per her personal experience. She has published it mainly to help beginners. These articles might have some problems. So bear with her and let her know if you find any problem in any of the article.

Leave a Comment