ASP implementation of long article manual paging code

Source: Internet
Author: User
Tags add manual end
<%
Set Recordset1=server.createobject ("Adodb.recordset")
Exec= "SELECT * from news where id=" &id
Recordset1. Open exec,conn,1,1
%>

<TD >
.......

<%
If Request ("page") = "" Then
Pagenum=0
Else
Pagenum=request ("page")
End If
Content=replace (Recordset1 ("content"), "", "| | |"
Contentstr=split (Content, "| | |")
For I=pagenum to Pagenum
%>
<%=contentstr (i)%>
<% Next%>


<%if UBound (contentstr) >=1 then%>

<TD height= > This paper is divided into
<%
For p = 0 To UBound (CONTENTSTR)
If p+1= Request ("page") +1 Then
A= ""
Aa= ""
Else
A= ""
Aa= ""
End If
%>
&page=<%=p%>" ><%=a%><%=p+1%><%=aa %>
<% Next%>
Page

<%end if%>

When you add an article, when you want to page out, add a separator.
This article links http://www.cxybl.com/html/wlbc/Asp/20120613/29965.html 


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.