Grow your CSS skills. Land your dream job.

Auto update text inside P tags generated by PHP

  • # June 27, 2013 at 8:32 pm

    Some of you may have seen a portion of my about page that shows the most recent article I’ve read and also the latest movies/shows I’ve watched. That content is updated randomly by me.

    I’m wondering, how can I get that content to change once I’ve updated it or even every few minutes without refreshing the page?

    URL: http://chrisburton.me/recently

    Code:

    var auto_refresh = setInterval(
    function()
    {
    $(‘#read’).load(‘index.php #read’);
    $(‘#watch’).load(‘index.php #watch’);
    }, 2000); // change to 60000 (1 minute) in production

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".