Working on the ajax long-polling code.