Create a “load more” widget using PHP, Ajax, and jQuery

Several months ago I created a post that was quite popular: Create a “load more” widget using PHP, Ajax, Mootools, Bootstrap and Mustache.js. Today I decided to port the code from Mootools to jQuery.

Prerequisite

This tutorial requires several prerequisite in order to be completed successfully:

  • The server needs to run PHP5 to be able to use JSON functions.
  • The widget does not need any custom CSS we will only use the famous Bootstrap Framework.
  • We will use the lastest version of jQuery (1.10.1)

For the logic please refer to Create a “load more” widget using PHP, Ajax, Mootools, Bootstrap and Mustache.js, and to see the code refer to the demo

5 thoughts on “Create a “load more” widget using PHP, Ajax, and jQuery”

  1. Hey I was wondering if you could help me with this problem.

    When I’m changing the variables, how do I echo the picture variable instead of placing a link that will show up for every different post.

    For example you have [http://julienrenaux.fr/demo/img/50×50.gif] as the image but every time i try to it doesn’t work. please help!

    1. PHP CODE modyfi
      $sql = “select … ,thm,post_name, id..”;

      Javascript Code Insert
      $post.find(‘.thumbnail’).attr(“src”,”http://julienrenaux.fr/demo/images/”+posts[post].thm);

  2. OHOH I wanner be. Thanks. x 1million
    i wanner it code google Searching for a 6month…
    At last, i founded this Site?blog? page~~~!!!!!
    but i just one thing is….
    First, i want coding style css not to be inline style.
    Second,PHP HTML JAVASCRIPT it’s Great But i want code CSS Style
    Thank you. Have a nice coinding ^^

Leave a Reply

Your email address will not be published. Required fields are marked *