前台代码:
<% String h_imgpath = URLEncoder.encode(h.getH_imgpath(), "utf-8"); %>
<a href="<%=request.getContextPath()%>/AdminHealthinfoDelete?id=<%=h.getId() %>&h_imgpath=<%=h_imgpath %>">删除</a>
后台代码
String h_imgpath = request.getParameter("h_imgpath");
String h_imgpath1 = URLDecoder.decode(h_imgpath, "utf-8");
System.out.println(h_imgpath);
System.out.println(h_imgpath1);