Quantcast
Channel: How to print scrollable DIV content - Stack Overflow
Viewing all articles
Browse latest Browse all 7

Answer by Jason Kyzer for How to print scrollable DIV content

$
0
0

Google messages updated their divs. Use this:

(function() {    var originalContents = document.body.innerHTML;    var printReport= document.querySelector("body > mw-app > mw-bootstrap > div > main > mw-main-container > div > mw-conversation-container > div > div > div > mws-messages-list")    document.body.innerHTML = printReport.innerHTML;    document.body.style.display = 'block';    document.body.style.overflow = 'visible';    window.print();    document.body.innerHTML = originalContents;}())

Viewing all articles
Browse latest Browse all 7

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>