I have two divs: div1 and div2.
div1
div2
Maintaining the original css styles applied to the div2 element being printed.
I don\'
.class-toggle { display: inline-block; } #div1, #div2 { display: none; }
function classToggle() { $('#div1').addClass('class-toggle'); } classToggle();
Then you can play with event handler to handle how and when you want to print the output.