Using @include directive in JSP
This directive is used to include a file (typically jsp or html) into a JSP page. Let us now see a simple example of how this works.
As you can see, you are passing an attribute called file with takes the file to be embedded.
JSP file - index.jsp
This is in the html body
out.println("This is in scriptlet");
<h2>This is a h2 heading</h2>
<p>This is a paragraph in sample.html</p>