getContextPath、getServletPath、getRequestURI的区别(转)
转自:http://veryls.iteye.com/blog/239830
假定你的web application 名称为news,你在浏览器中输入请求路径: http://localhost:8080/news/main/list.jsp 则执行下面向行代码后打印出如下结果: 1、 System.out.println(request.getContextPath()); //可返回站点...
原创
2014-03-06 09:32:56 ·
58 阅读 ·
0 评论