A Basic JSP example


JavaServer Pages allow you to create dynamic webpages using Java code.

    <title>A Simple JSP Page</title>

This is template text; it is automatically written to the output


<%-- This is a JSP comment --%>


    // This is a scriptlet; it contains Java code


The following is a JSP expression; it is used to emit dynamic
text to the output stream: 
The current date is <%= new java.util.Date() %>


The following is a directive that includes other files:
<%@ include file="fragment.jsp" %>



Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.