在jsp页面中:
<%
String path = application.getRealPath("").replace("\\","\\\\");
%>
在java代码中:
String path = request.getServletContext().getRealPath("").replace("\\","\\\\");
2023-08-10 09:11:10
在jsp页面中:
<%
String path = application.getRealPath("").replace("\\","\\\\");
%>
在java代码中:
String path = request.getServletContext().getRealPath("").replace("\\","\\\\");