This topic is locked

pagination list 5 instead of 10

11/17/2022 12:44:41 PM
PHPRunner General questions
P
ppradhan@live.com author

How to have pagination only upto 5 (default is 10) in the list page, like in the preview below?
Becuase while viewing the page in mobile, the layout looks ugly having 10 steps in pagination. Please advice how I can achieve 1-5 pagination list only.

img alt

P
ppradhan@live.com author 11/18/2022

I used custom css and looks nice visually. But the problem is when I click Next it uses pagination of 10 range and skips the rest, I wanted the range of 5.
Please help if anyone have already come accross this such issue.

// Custom CSS
@media screen and (max-width: 600px) {

.pagination li:nth-of-type(1n+6) {
display: none;
}

.pagination li:nth-last-child(-n+2) {
display: inline-block;
}

}

First Screen

img alt

clicking at Next will start from 11

Second Screen

img alt

DealerModulesDevClub member 11/18/2022

In your PHPRunner, just go to the "Misc" page from the menu on the bottom and change:
"Records per page selection" to 1,5,10,15,20,25,All and
"Records per page" to 5. (This will change it for just that page)

img alt

Paul

P
ppradhan@live.com author 11/19/2022

@DealerModules11,
this way the pagination for webview in laptop also goes to 5.
I wanted 10 in desktop and 5 in mobile to reduce the space used by pagination while at mobile view.

fhumanes 11/21/2022

Hello,
img alt

I think this is the code that controls the pagination on the pages List.

How you see, it is coded to do it 10 or 5, depending on whether it is on mobile or not.

It has not worked for me or I have not been able to inform you that I am working on a mobile.

The only thing I have left is to modify this code so that in all cases 5 links or blocks are.

Cheers,
fernando