JSP Syntax

The syntax of JSP is almost similar to that of XML. ALL JSP tags must conform to the following general rules:

  • Tags must have their matching end tags.
  • Attributes must appear in the start tag.
  • Attribute values in the tag must be quoted.

White spaces within the body text of a JSP page are preserved during the translation phase. To use special characters such as ‘%’, add a ‘\’ character before it. To use the ‘\’ character, add another ‘\’ character before it.

Source: Uttam Kumar Roy (2015), Advanced Java programming, Oxford University Press.

Leave a Reply

Your email address will not be published. Required fields are marked *