title: Printing an HTML form using jQuery
body: <p>I am having an HTML form, and I need to print(HardCopy) particular area..</p>
  <p>The problem is I am unable to get the form Text1 and Text2 values on the. Since I need that HTML form to be filled with some value, while clicking <em>print it</em> should print as hardcopy.</p>
  <h3>My Code</h3>
  <pre><code>        &lt;script type=&quot;text/javascript&quot;&gt;
              $(document).ready(function(){
                  $(&quot;#print&quot;).click(function(){
                     alert($('#click').html());
                     // It shows only form elements; I need a form typed element too. How?
                     window.print();
                  });
              });
          &lt;/script&gt;
      &lt;/head&gt;
      &lt;body&gt;
          &lt;form id=&quot;click&quot;&gt;
              Text1: &lt;input id=&quot;l&quot; type=&quot;text&quot; /&gt;
              Text2: &lt;input id=&quot;m&quot; type=&quot;text&quot;/&gt;
              &lt;input id=&quot;print&quot; type=&quot;button&quot; value=&quot;Print-Me&quot;/&gt;
          &lt;/form&gt;
      &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>