However, it never works. Is there a way I can fix it so that when the user starts typing, the focus *always* goes to the text input box and their text appears there? Right now the user has to actually click in the input box to start typing... and if they switch to a different browser window and then click back into the chat window, they have to click again into the text input. It's really a hassle. I want to make it more user-friendly, but can't seem to get the setFocus thing to work.