A JSP page mainly comprises the following types of code.
• HTML Code
HTML code is used for displaying the HTML output like text field, check box, option menu where user can give requested data to the web application and also for generating other static content of the web page. HTML codes can be embedded easily in the JSP page.
• Scripting Code
Scripting code means the codes which have nested in some other code without any extension. Like JavaScript code it is used in JSP page to get some more dynamism like email id validation, password field length validation, etc.
• Scripting Tags
Java codes are placed inside the scripting tags. There are three types of scripting tags in JSP: Scriptlet Tag, Declaration Tag, Expression Tag.
Template Text
Template text is a combination of normal text and HTML code. It is the uninterrupted data of a JSP page. It is guides the end user when entering data in the required fields.