when you publish an article, add a preset page break where you want it to be paged.
Implementation steps:
One, my backstage editor is FCK, how to let it have this function? The easiest way to do this is to replace a button that is not commonly used with the Insert Page Break button. (There are two files in the FCK folder "Fckeditor\editor\js", Fckeditorcode_gecko.js and Fckeditorcode_ Ie.js, give them the operation is OK, specifically do not say, no source files on hand, I do not know the specific code, interested in the friend PM me i preset the "<div>::</div>" as a page break, this casually set, As long as it does not appear in the article to the normal display of the line.
Second, write the front article display page code, how to link the database, read the database and other code will not say. Here is the key code:
' article page number parameter, starting from 1
page = request.querystring ("page")
' Split article by page break
Arrcontent = Split (RS ("article literal segment"), "<div>::</div>"
' Show the body of the article on the specified page
Arrcontent (page-1)
' Article pagination page Number link
Call Textpage (UBound (arrcontent))
Textpage function Code:
The following is a reference fragment: Code: <% function Textpage (Pages) If Pages > 0 Then Response.Write (VbCrlf & "<div class=" "Textpage" ">") For p = 1 to Pages+1 Response.Write ("<a href=" "id=" & ID & "&page=" & P & "" ">" & P & "page </a> |") Next Response.Write ("</div>") End If End Function %> |