jsp中地址

其中prj_01是应用名

path:  <%=request.getContextPath() %><br/>
 schema: <%=request.getScheme() %><br/>
 serverName: <%=request.getServerName() %><br/>
 serverPort: <%=request.getServerPort() %><br/>
 bathPath: <%=request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/"%><br/>

显示

path: /prj_01
schema: http
serverName: localhost
serverPort:
8080
bathPath: http://localhost:8080/prj_01/

posted @ 2013-02-08 10:26  IamThat  阅读(251)  评论(0编辑  收藏  举报