Hi there,
I would like to print a page or create a pdf (print to pdf).
This is a brand new topic for me and I am a little overwhelmed.
I was able to create some local html tests but was not able to apply them to Cwicly.
Can anyone give me a hint in the right direction or does Cwicly already have a solution that I’ve missed?
// Function to print the page
function printPage() {
window.print();
}
// Attach the printPage function to the button's click event
var printButton = document.getElementById("printButton");
printButton.addEventListener("click", printPage);
Thank you for your solutions @kane and @Marius.
Both solutions worked like a charm.
Previously, I tried setting up the window.print(); command in the interactions section. But I seem to have missed something. Would this also be a possibility?
If I only want to print a specific area, would it be correct to create custom css like this?