I have a chatbox thing on a webpage hooked up to a WebSocket. I was just wondering how I keep the chatbox always scolled to the bottom. I have something that kind of works but it breaks too easily. Take a look here: http://sightofnick.com/public/sub-routine(alpha-24)/public.socket.io.html
Thanks in advance for suggestions.
EDIT: I guess what I'm asking is, what is the best way to keep the scroll pinned to the bottom?