JSP Tutorial - Javatpoint
JSP Tutorial - Javatpoint
1 of 5
http://www.javatpoint.com/jsp-tutorial
Content Menu
20/11/2014 3:56 PM
2 of 5
http://www.javatpoint.com/jsp-tutorial
JSP Tutorial
JSP technology is used to create web application just like Servlet
technology. It can be thought of as an extension to servlet
because it provides more functionality than servlet such as
expression language, jstl etc.
A JSP page consists of HTML tags and JSP tags. The jsp pages are
easier to maintain than servlet because we can separate
designing and development. It provides some additional features such as Expression
Language, Custom Tag etc.
1) Extension to Servlet
JSP technology is the extension to servlet technology. We can use all the features of
servlet in JSP. In addition to, we can use implicit objects, predefined tags, expression
language and Custom tags in JSP, that makes JSP development easy.
2) Easy to maintain
JSP can be easily managed because we can easily separate our business logic with
presentation logic. In servlet technology, we mix our business logic with the
presentation logic.
20/11/2014 3:56 PM
3 of 5
http://www.javatpoint.com/jsp-tutorial
Note: jspInit(), _jspService() and jspDestroy() are the life cycle methods
of JSP.
As depicted in the above diagram, JSP page is translated into servlet by the help of JSP
translator. The JSP translator is a part of webserver that is responsible to translate the
JSP page into servlet. Afterthat Servlet page is compiled by the compiler and gets
converted into the class file. Moreover, all the processes that happens in servlet is
performed on JSP later like initialization, committing response to the browser and
destroy.
20/11/2014 3:56 PM
4 of 5
http://www.javatpoint.com/jsp-tutorial
</html>
It will print 10 on the browser.
20/11/2014 3:56 PM
5 of 5
http://www.javatpoint.com/jsp-tutorial
scriptlet tag
expression tag
declaration tag
5. Implicit Objects
6. Directive elements
page directive
include directive
taglib directive
7. Exception Handling
8. Action Elements
9. Expression Language
10. MVC in JSP
11. JSTL
12. Custom tags
13. Development in JSP
<<prev
next>>
20/11/2014 3:56 PM