title: How can i use Javascript variable as argument in java code in JSP?
body: <p>I want to send code title and price as an argument to the book object but gives illegal start expression error.</p>
  
  <pre><code> function addrecord() {
      code = document.getElementById('code').value;
              title = document.getElementById('title').value;
              price = parseFloat(document.getElementById('price').value);
  
      &lt;%   Book book = new Book(%&gt; code &lt;% ,%&gt; title &lt;% , %&gt; price &lt;% );
     bookdb.addRecord(book);   
               %&gt;
              document.getElementById("code").value = "";
              document.getElementById("title").value = "";
              document.getElementById("price").value = "";
      }
  </code></pre>