<% dim numsql,numrs,pagenum numsql="select content from [num]" set numrs=conn.execute(numsql) if numrs.eof Then pagenum=20 Else pagenum=numrs("content") End If %> 旅游达人信息管理系统 <% '有时文章标题比较长影响排版用这个函数截取标题的一部分来显示 function gotTopic(str,strlen) dim l,t,c, i l=len(str) t=0 for i=1 to l c=Abs(Asc(Mid(str,i,1))) if c>255 then t=t+2 else t=t+1 end if if t>=strlen then gotTopic=left(str,i)&"..." exit for else gotTopic=str&" " end if next end function %>
<%dim sql,rs,page,k,tmppage If Len(Trim(Request("page")))=0 Then '返回目标页码的判断 page=1 Else page=CInt(Trim(Request("page"))) End If set rs=Server.CreateObject("ADODB.RecordSet") sql="select * from [article] order by 编号 desc" rs.open sql,conn,1,1 rs.PageSize=pagenum if not rs.eof then rs.AbsolutePage=page for k=1 to rs.PageSize %> <% rs.movenext if rs.EOF Then Exit For next end if %>
会社名
ロゴ
URL
会社案内
カテゴリ
   &sort=<%=rs("sort")%> target="_blank" title=已浏览<%=rs("browse")%>次,发布日期:<%=rs("date")%>><%=Juncode(rs("comname"))%> " width="100" height="28" border="0"> <%=rs("comadd")%>

"><%=gottopic(Juncode(rs("content")),32)%>

<%=Juncode(rs("sort"))%>

  <% if page <>1 then Response.Write "首页  " end if tmppage = page - 1 if tmppage <= 0 then tmppage = 1 else Response.Write"上一页 " end if tmppage = page + 1 if tmppage >rs.PageCount then tmppage = page else Response.Write " 下一页  " end if if Cstr(page) <> Cstr(rs.PageCount) and Cstr(rs.PageCount) <> 0 then Response.Write "尾页 " end if if Cstr(rs.PageCount) <> 0 then Response.Write " 第" & page & "/"&rs.PageCount&"页 " end if Response.Write "  共有"&rs.RecordCount&"条记录" %>

<%Function FormatWord(ly) ly=server.HTMLEncode(ly) ly=Replace(ly, "'", "'") ly=Replace(ly, chr(13) & chr(10), "
") ly=Replace(ly, chr(10), "
") ly=Replace(ly, chr(13), "
") ly=Replace(ly,CHR(32)," ") FormatWord=ly End function %>