Skip to content

Instantly share code, notes, and snippets.

@aaaronic
Created November 2, 2013 03:03
Show Gist options
  • Save aaaronic/7274987 to your computer and use it in GitHub Desktop.
Save aaaronic/7274987 to your computer and use it in GitHub Desktop.
Comcast online chat support service refusing to scroll to the bottom of the chat content div automatically when messages arrive from the "analyst" (might just be a Chrome bug, I'm not sure)? Paste the (admittedly simplistic) script into the js console, so you can focus back onto the real task at hand.
(function (window, jQuery) {
var div = document.getElementById("ChatOutput");
function fixIt() {
div.scrollTop = div.scrollHeight;
}
if (div) {
window.setInterval(fixIt, 100);
}
})(window, jQuery);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment