Knowledge is not enough, Apply it.
JSP Mapping in Web.xml
<servlet>
<servlet-name>HeaderPage</servlet-name>
<jsp-file>/Common/header.jsp</jsp-file>
</servlet>
<servlet-mapping>
<servlet-name>HeaderPage</servlet-name>
<url-pattern>/header.jsp</url-pattern>
</servlet-mapping>
Define a filter and then map it to the jsp.
This way we can avoid the full path specification in the url.
(Whatever url pattern we specify, call it from the browser. It will answer :-)
Very useful in configuring the filters for jsp pages.
JSP Mapping in Web.xml
<servlet>
<servlet-name>HeaderPage</servlet-name>
<jsp-file>/Common/header.jsp</jsp-file>
</servlet>
<servlet-mapping>
<servlet-name>HeaderPage</servlet-name>
<url-pattern>/header.jsp</url-pattern>
</servlet-mapping>
Define a filter and then map it to the jsp.
This way we can avoid the full path specification in the url.
(Whatever url pattern we specify, call it from the browser. It will answer :-)
Very useful in configuring the filters for jsp pages.