title: How can I convert input from an html form into a Java String variable?
body: <p>I've created a .jsp file that is a form that takes in common information, e.g. name, address, email. I am using html forms along these lines:</p>
  
  <pre><code>&lt;form&gt;
  First name: &lt;input type="text" name="firstname"&gt;&lt;br&gt;
  Last name: &lt;input type="text" name="lastname"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>But how do I take the input and save it to a String variable? I then want to take that variable and pass into a class that creates client objects. This is my first web app I've tried to build and I am really struggling. Any help regarding taking user input for a web application would be greatly appreciated.</p>