jsp 加载公用js
2018-07-24 本文已影响11人
小郭米
common.jsp
<%
String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + request.getContextPath();
request.setAttribute("basePath", basePath);
%>
页面引用
link rel="stylesheet" type="text/css" href="${basePath}/css/jquery.validate.css"