<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%> 后台管理

" method="post">
新闻管理 '">
 
<% sql="select * from news where sort="&trim(request("sort")) if trim(request("types"))<>"" then sql=sql&" and types="&trim(request("types")) end if if trim(request("Keyword"))<>"" then dim KeyWord KeyWord=trim(Request("KeyWord")) sql=sql&" and title like '%"&KeyWord&"%'" end if sql=sql&" order by regtime desc" set rs=server.CreateObject("ADODB.Recordset") rs.open sql,conn,1,1 if rs.eof then response.Write "" else proCount=rs.recordcount rs.PageSize=18 if not IsEmpty(Request("ToPage")) then ToPage=CInt(Request("ToPage")) if ToPage>rs.PageCount then rs.AbsolutePage=rs.PageCount intCurPage=rs.PageCount elseif ToPage<=0 then rs.AbsolutePage=1 intCurPage=1 else rs.AbsolutePage=ToPage intCurPage=ToPage end if else rs.AbsolutePage=1 intCurPage=1 end if intCurPage=CInt(intCurPage) For i = 1 to rs.PageSize if rs.EOF then Exit For end if '利用for next 循环依次读出记录 %> <% rs.MoveNext next %> &types=<%=trim(request("types"))%>"> <% rs.close Set rs = Nothing end if %>
新闻标题 新闻类别 新闻编辑 添加时间 相关操作
暂无信息
<%=rs("title")%><%if rs("genre")=1 then response.write "  图"%><%if rs("tj")=1 then response.write "  荐"%><%if rs("rd")=1 and trim(request("sort"))=1 then response.write "  热"%> <% set rs1=server.CreateObject("ADODB.Recordset") rs1.open "select * from news_type where id="&rs("types"),conn,1,1 if not rs1.eof then response.write ""&rs1("names")&"" end if rs1.close set rs1=nothing %> <%=rs("write_name")%> <%=rs("regtime")%> ">修改 &sort=<%=trim(request("sort"))%>" onClick="return confirm('你确定删除吗?\n\n如果删除将无法恢复数据.')">删除
总共:<%=rs.PageCount%>页,<%=proCount%>条新闻, 当前页:<%=intCurPage%> <%if intCurPage<>1 then%>&types=<%=trim(request("types"))%>&Keyword=<%=Server.URLEncode(request("Keyword"))%>">首页|&types=<%=trim(request("types"))%>&Keyword=<%=Server.URLEncode(request("Keyword"))%>">上一页|<%end if%> <%if intCurPage<>rs.PageCount then%>&types=<%=trim(request("types"))%>&Keyword=<%=Server.URLEncode(request("Keyword"))%>">下一页|&types=<%=trim(request("types"))%>&Keyword=<%=Server.URLEncode(request("Keyword"))%>"> 最后页|<%end if%> 跳转: