Like Nilesh said, the two include techniques are different. The
include directive puts the contents of the included page directly
inside of the JSP when it is translated into
Java code and compiled. This means that if the included page contains dynamic content,
it will never change (because it was evaluated only once). The
include standard action includes the page
every single time so that dynamic content shows up. So the include directive is better for static content and the include standard action is better for dynamic content.
Because the include directive puts the contents of the file directly inside of the JSP, you can use page scope.
index.jsp:
another.page.jsp:
But if using the include standard action, you must use request scope because the included page exists in a separate page scope.
index.jsp:
another.page.jsp:
I hope that helps you..