Solve the paging problem of Bo Yi 2.0

Source: Internet
Author: User

Blog updated todayProgramI used the blog www.blogyi.net and upgraded it from 1.9 to 2.0. After the upgrade, a small problem was found, and 2.0 of the pages encountered a problem.

2 fewer!

There is no way to change the source code.

1.find blogyi.net-2.0-source.zip \ blogengine. Net \ app_code \ controls \ postpager. CS to open

Find

 
// Always show last two // pages. Add (total-1); // By spoony pages. Add (total );

About 145 rows
Change

 
// Always show last two pages. Add (total-1); // By spoony // pages. Add (total );

I think the author spoony is too careless and wrong. Here we can change it back to spoony.

2. The following changes are not necessary, but I personally think the changes are more appropriate. If you do not change this part, the page number on the last page is not displayed when you flip the page to the last page. Turning pages to the first page is an arrow, not very symmetrical.
211 rows found

If (currentpage = 1) {// retvalue + = string. format (linkdisabled, labels. nextposts); retvalue + = string. format (linkdisabled, "<"); // By spoony}

Change

 
If (currentpage = 1) {// retvalue + = string. format (linkdisabled, labels. nextposts); retvalue + = string. format (linkdisabled, "1"); // By spoony}

Find Row 3

 
If (currentpage = pagestotal) {// retvalue + = string. format (linkdisabled, labels. previousposts); retvalue + = string. format (linkdisabled, ">"); // By spoony}

Change

If (currentpage = pagestotal) {// retvalue + = string. format (linkdisabled, labels. previousposts); retvalue + = string. format (linkdisabled, pagestotal); // By spoony}

Recompile and update the upload server.

 

Normal.

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.