Creating a simple pagination using php and mysql

Поделиться
HTML-код
  • Опубликовано: 22 фев 2023
  • In this tutorial we are going to explain step by step, how to create a
    pagination using php and mysql.
    You can read the article here:
    digitalfox-tutorials.com/tuto...
    You can buy me a coffee and get the whole source code in a zip file.
    www.patreon.com/Digitalfox13/...

Комментарии • 44

  • @NoelReinhardt
    @NoelReinhardt 5 месяцев назад +2

    you explain this in a very easy understanding language! love this man! really helpful for my project

  • @lazybusylog5081
    @lazybusylog5081 Год назад +1

    Thanks! Quick and easy explanation! Nice job!

  • @user-yg1nm6vj4b
    @user-yg1nm6vj4b 7 месяцев назад +1

    Amazing tutorial, you explain things beautifully. Thank you!

  • @dinidumadushan4749
    @dinidumadushan4749 10 месяцев назад

    really helpful. thank you very much..

  • @conradunderwood6742
    @conradunderwood6742 Год назад +1

    Thanks for this video. It was easy to follow and helped me a lot

  • @abdulghaffar3110
    @abdulghaffar3110 3 месяца назад

    Hi! very nice video for my project thanks.

  • @jpacs3738
    @jpacs3738 Месяц назад

    Thank you so much! This is very helpful tutorial. You're awesome!

  • @marcofloriano
    @marcofloriano 7 дней назад

    Amazing tutorial nice job

  • @lordcarlocabangal5713
    @lordcarlocabangal5713 8 месяцев назад

    very useful tutorial!!!! Thanks a lot!!!

  • @rodolfosgc1882
    @rodolfosgc1882 4 месяца назад

    Gracias me funciono

  • @VlkSamotar
    @VlkSamotar 11 месяцев назад

    It was very useful for me. Thank you.

  • @aymdatenth1796
    @aymdatenth1796 Год назад

    thank you this was quick and easy without the use of bootstrap

  • @samuelagbo2947
    @samuelagbo2947 11 месяцев назад

    Thanks alot

  • @cecilbennett289
    @cecilbennett289 2 месяца назад

    Wow this is a nice video man, thank you so much 💪💡

  • @d.o.balogun3228
    @d.o.balogun3228 Год назад

    Good job

  • @ngetsophea8812
    @ngetsophea8812 6 месяцев назад +1

    I tested the style "active" in the JS on my end. I use +1 in stead of -1, it's working. I still don't know when I use -1, it's two steps behind the active page. For example, I am on page 4, but the active page show on page 2.

  • @NtiranyibagiraFelicien
    @NtiranyibagiraFelicien 2 месяца назад

    tHANKS bUT yOU eXPLAIN qUIKLY.

  • @sdsd-ec8rw
    @sdsd-ec8rw 10 месяцев назад +3

    do you have a video for the case when there are a lot of pages that don't fit in the screen? I think it is important to address this case

    • @DigitalFox-tutorials
      @DigitalFox-tutorials  10 месяцев назад +2

      Hey, no i don't, but you are right. I will try to do a video on it.

  • @Animeheavens
    @Animeheavens Год назад

    Bruh I like ur voise 😂❤

  • @YtResolver
    @YtResolver 25 дней назад

    Hi thanks alot can you make the other one where you scroll to initiate the pagination to move to the next pages automatically without clicking do it with no frameworks like jquery and bootstrap as other youtubers have done it.

  • @parakeetbird863
    @parakeetbird863 3 месяца назад

    can you make a video on how I can make it dynamic, where if I have more than 5 pages the next numbers would show us an ellipsis and the same if the first page number can't be seen

  • @photoinshot1355
    @photoinshot1355 Год назад

    Great video thanks! Is there a way to search a paginated table?

    • @DigitalFox-tutorials
      @DigitalFox-tutorials  Год назад

      Thank you. Yes, we can use javascript to fetch all the results, (titles), from the page and then search through them.

  • @OnyeStephen
    @OnyeStephen 7 месяцев назад

    Amazing tutorial, but as a curious student, if a user sets the page-nr = 0 or less than 0, it displays an error or says (showing -3434 of 10pages) is there a way to fix this so that if the value of the page-nr = 0 or less than 0 the page-nr is automatically set to 1. Used this code to fix it if(!is_numeric($_GET["page-nr"]) || ($_GET["page-nr"] $pages) ){
    //here we are making sure that if the user sets the page through the url a value that is not numeric, less than 0 or greater than the number of pages from the database, we referesh the page
    header("Location:index.php");
    } else {
    $page = $_GET["page-nr"] - 1;
    }

    • @PhongLan315
      @PhongLan315 7 месяцев назад +1

      Where to put that code?

    • @OnyeStephen
      @OnyeStephen 7 месяцев назад

      @@PhongLan315have the code where you set the page start point $page on the php scripts page

    • @DigitalFox-tutorials
      @DigitalFox-tutorials  7 месяцев назад

      @PhongLan315 Hey, replace the $page = $_GET['page-nr'] - 1; in the script.php file withe the clever solution that @OnyeStephen provided. I mean the whole if statement.

    • @DigitalFox-tutorials
      @DigitalFox-tutorials  7 месяцев назад

      @OnyeStephen Hey, nice, i had that in my mind but i forgot during the recording.
      Great work.