How to directly access files under the WEB-INF, access the web-inf file
<Servlet> <servlet-name> HE </servlet-name> <jsp-file>/WEB-INF/u_member/Login. jsp </jsp-file> </servlet> <servlet-mapping> <servlet-name> HE </servlet-name> <url-pattern>/Login. jsp </url-pattern> </servlet-mapping>
After configuration, you can directly access Login. jsp.
How does Struts access jsp files under the WEB-INF directory?
Jsp files under the WEB-INF directory cannot be accessed directly in the browser. (No access permission) if you put the jsp file under the WEB-INF directory, it will not be accessible. For example, writing <a href =/WEB-INF/content/index. jsp directly on the jsp page will not be accessible. In struts, you must use action to achieve page Jump, in order to access the jsp file in the WEB-INF. Write the link in the preceding jsp page as: <a href = index. action in the struts configuration file to add such a sentence: <action name = * <result/WEB-INF/content/{1 }. jsp </result </action indicates that all actions on the page will jump to the jsp page of the corresponding action under/WEB-INF/conent. Of course, if other specific actions are prefixed, the corresponding jsp page is displayed. By adding the above action, the page hyperlink is positioned below the WEB-INF/content directory.
How to access files under the WEB-INF directory
I am not a master either .. However, this does not seem to be the correct method.