<%@ page language="java" import="java.util.*" pageEncoding="gb2312"%> <%@page import="util.Info"%> <%@page import="dao.CommDAO"%> <%@page import="util.PageManager"%> 评论

已有评论列表:

搜索:评论内容: 评论人
<% new CommDAO().delete(request,"pinglun"); String id=request.getParameter("id"); String url = "pinglun_list.jsp?id="+id; String sql = "select * from pinglun where xinwenID="+id; if(request.getParameter("pinglunneirong")=="" ||request.getParameter("pinglunneirong")==null ){}else{sql=sql+" and pinglunneirong like '%"+request.getParameter("pinglunneirong")+"%'";} if(request.getParameter("pinglunren")=="" ||request.getParameter("pinglunren")==null ){}else{sql=sql+" and pinglunren like '%"+request.getParameter("pinglunren")+"%'";} sql+=" order by id desc"; //out.print(sql); ArrayList list = PageManager.getPages(url,20,sql, request ); int i=0; for(HashMap map:list){ i++; %> <% } %>
序号 数据ID [对应表] 评论内容评论人 评论时间 操作
<%=i %> <%=map.get("xinwenID") %> [<%= map.get("biao")%>] <%= map.get("pinglunneirong")%><%= map.get("pinglunren")%> <%=map.get("addtime") %> 删除

以上数据共<%=i %>条,打印本页