方法一
--得到 href="http://localhost:8080/shop06/" />
图片显示,注意别加/ 写成了 <img src="/images/edit.gif
方法二
<base
<% String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";%>
href="<%=basePath%>" />
--得到 href="http://localhost:8080/shop06/" />
图片显示,注意别加/ 写成了 <img src="/images/edit.gif
<tr>
<td bgcolor="f5f5f5"> <div align="center"><a href=''>
<img src="images/edit.gif" width="15" height="16" border="0"></a></div></td>
</tr>
方法二
<tr>
<td bgcolor="f5f5f5"> <div align="center"><a href=''>
<img src="${pageContext.request.contextPath}/images/edit.gif" width="15" height="16" border="0"></a></div></td>
</tr>