Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#15983 closed defect (bug) (fixed)

Pagination controls aren't shown when an AJAX request returns more than one page

Reported by: nacin Owned by:
Milestone: 3.1 Priority: normal
Severity: normal Version:
Component: Administration Keywords: has-patch
Focuses: Cc:


If you run a filter or search to the point where you have only one page of results, you won't have any pagination controls. (You'll need to refresh the page or what not in order to make sure no controls are rendered.)

Then, clear the filter or the search. You'll end up with many pages of results, but no pagination controls.

Suggested fix: Always print the paginated controls (only if max items > number per page, if preferred). Hide them with CSS as appropriate (inject a display:none or something). Then show if necessary after an AJAX result.

Attachments (1)

15983.diff (1.7 KB) - added by nacin 5 years ago.

Download all attachments as: .zip

Change History (3)

@nacin5 years ago

comment:1 @nacin5 years ago

  • Keywords has-patch added

Easier than I thought. Patch attached.

comment:2 @ryan5 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [17156]) Always output pagination controls. Hide them when they are not needed. Show them upon AJAX result that requires pagination. Props nacin. fixes #15983

Note: See TracTickets for help on using tickets.