开发者

pagination in php [closed]

开发者 https://www.devze.com 2023-02-07 15:34 出处:网络
It's difficult to tell what is being asked here.开发者_C百科 This question is ambiguous, vague, incomplete, overly broad, or rhetorical andcannot be reasonably answered in its current form. Fo
It's difficult to tell what is being asked here.开发者_C百科 This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 12 years ago.

want search result for displaying exactly same result as in : https://www.ippu.purdue.edu/GlobalLinkages/index.cfm?Location=.&Page=search

1 - 25 of 414 records Next >

I am using 3 inputs frm user ant it is same as link provided above


Use MySQL's LIMIT and OFFSET constructs:

$offset = ($current_page - 1) * $items_per_page;
// in your query:
LIMIT $items_per_page OFFSET $offset


I'd check out the Pager class in the PEAR repository. It's what I use for this sort of thing, and it has a bunch of options you can set.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号