JAVA、JSP中获得URL地址
两个方法是有区别的
request.getRequestURI() 返回值类似:/project/index.jsp
request.getRequestURL() 返回值类似http://localhost:8080/project/index.jsp
分类: java 3,341 次阅读
原文链接:http://www.wenhq.com/article/view_337.html欢迎转载,请注明出处:亲亲宝宝
两个方法是有区别的
request.getRequestURI() 返回值类似:/project/index.jsp
request.getRequestURL() 返回值类似http://localhost:8080/project/index.jsp