©2003-2025 BeyondTrust Corporation. All Rights Reserved. Other trademarks identified on this page are owned by their respective owners. BeyondTrust is not a chartered bank or trust company, or depository institution. It is not authorized to accept deposits or trust accounts and is not licensed or regulated by any state or federal banking authority.

`; // Create off-screen iframe, write the printHTML, then call print const iframe = document.createElement('iframe'); Object.assign(iframe.style, { position: 'fixed', width: '0', height: '0', border: 'none', right: '0', bottom: '0' }); document.body.appendChild(iframe); const doc = iframe.contentWindow.document; doc.open(); doc.write(printHTML); doc.close(); const imgInFrame = doc.getElementById('print-header').querySelector('img'); imgInFrame.onload = () => { iframe.contentWindow.focus(); iframe.contentWindow.print(); setTimeout(() => iframe.remove(), 500); }; imgInFrame.onerror = () => { alert('Failed to load header in print preview.'); iframe.remove(); }; }); container.appendChild(btn); } setInterval(addPrintButton, 500); })();