Archived topic
How to show pagination like this
9 replies · Started by Ajay Nehra on December 31, 2021
How to show pagination like this >> https://ibb.co/fS9KNvz
Give this CSS a try:
.paging-navigation .nav-links>* {
padding: 10px 16px;
background-color: lightgrey;
color: black;
border-radius: 4px;
}
.paging-navigation .nav-links span.page-numbers.current {
background: blue;
color: #ffffff;
}
I also want to remove the "dots"
And I want to change "Next →" as well. please check the image
Can you link me to your site?
please check Private information
1. Add this PHP snippet to show all the page numbers:
add_filter( 'generate_pagination_mid_size','tu_increase_pagination_numbers' );
function tu_increase_pagination_numbers() {
return 100;
}
Adding PHP: https://docs.generatepress.com/article/adding-php/
2. Change the CSS to this:
.paging-navigation .nav-links>* {
padding: 10px 16px;
background-color: lightgrey;
color: black;
border-radius: 4px;
}
.paging-navigation .nav-links span.page-numbers.current {
background: blue;
color: #ffffff;
}
a.next.page-numbers > span {
display: none;
}
how to replace next with » and Previous with «
Hi there,
These two docs provide the PHP snippets for changing the previous and next link text:
https://docs.generatepress.com/article/generate_previous_link_text/
https://docs.generatepress.com/article/generate_next_link_text/
Thanks
You're welcome