tags:

views:

64

answers:

1

Hi,

I'm building a basic forum where each post contains a name, a message and a date. The forum is written in PHP and updates with AJAX to load new posts on the fly. When new posts come in, I would like the old posts to ease down nicely (much like facebook does today when you have new updates) and to make room for the new posts. Can anyone point me in the direction of how to go about something like this?

+1  A: 

This is a very stupid example but...

Say you have a page with a button id="foo"

and a style sheet with: .bar{display: none;}

Then this js:

$("#foo").click(function(){

        $(this).before("<div class='bar'><p>HELLO!</p><br /><p>WORLD!</p><div>");
        $(".bar:first").slideDown("slow");

});

This should give the effect you're looking for.

rpcutts
let me know if this doesn't help.
rpcutts