[Code] Need help for Pagination

skypeleft

Active member
Aug 10, 2019
401
71
28
Hi all pro coder, I'm not a coder, I have a link manager page, with pagination with the problem: more than 24 pages but it's not showing for me.
I mean I want the page number to be collapsed. Next does not appear for me, pages after 24 are overflowing. Please see the picture I attached, please help.

Code:
 <!-- Pagination -->
        <nav aria-label="Page navigation example mt-5">
            <ul class="pagination content-center">
                <li class="page-item <?php if($page <= 1){ echo 'disabled'; } ?>">
                    <a class="page-link"
                        href="<?php if($page <= 1){ echo '#'; } else { echo "?page=" . $prev. $linksearch ; } ?>">Previous</a>
                </li>

                <?php for($i = 1; $i <= $totoalPages; $i++ ): ?>
                <li class="page-item <?php if($page == $i) {echo 'active'; } ?>">
                    <a class="page-link" href="link.php?page=<?= $i. $linksearch ; ?>"> <?= $i; ?> </a>
                </li>
                <?php endfor; ?>

                <li class="page-item <?php if($page >= $totoalPages) { echo 'disabled'; } ?>">
                    <a class="page-link"
                        href="<?php if($page >= $totoalPages){ echo '#'; } else {echo "?page=". $next. $linksearch ; } ?>">Next</a>
                </li>
            </ul>
        </nav>
             </div>
            </div>
          </div>

2022-05-14 09_38_57-Admin.png
 

About us

  • Our community has been around for many years and pride ourselves on offering unbiased, critical discussion among people of all different backgrounds. We are working every day to make sure our community is one of the best.

Quick Navigation

User Menu