1.java表达式:<%=this.getServletContext().getContextPath() %>

2.el标签通过标签: ${pageContext.request.contextPath}