Don't use short open tags for PHP as they are not turned on by default in production environments.
Again, the chatbox needs help from the jQuery migrate plugin.