document.addEventListener("DOMContentLoaded", function() { window.print(); });