title: How to print only a selected HTML element?
body: <p>I am trying to implement a print feature in HTML. I know I can print the whole page with <code>window.print()</code>, but how do I print only a specific page element? For example a particular <code>&lt;DIV&gt;Some text to print&lt;/DIV&gt;</code>.</p>