HTTP GET Request with Input
'); printFrameWindow.document.close(); printFrameWindow.focus(); // Important for some browsers printFrameWindow.print(); printFrameWindow.document.close(); // Close after printing (good practice) } else { console.error("Could not get iframe window object."); alert("Error: Could not print the content."); } }); inputForm.addEventListener('submit', function(event) { event.preventDefault(); });