title: Bind input values in textbox using knockout to send to server.
body: <p>Using knockout i would like to accept submitted values and send them to server using ko.toJson. I am new to knockout and am sure i having some syntactic issues. More concisely i want my submit button to save the values in my textbox and save them to server. 
  here is my fiddle <a href="https://jsfiddle.net/Domt301/30h3oe9t/" rel="nofollow">https://jsfiddle.net/Domt301/30h3oe9t/</a></p>
  
  <pre><code>&lt;div class='Agent Form'&gt;   
  &lt;p&gt;First name: &lt;input data-bind='value: firstName' /&gt;&lt;/p&gt; 
  &lt;p&gt;Last name: &lt;input data-bind='value: lastName' /&gt;&lt;/p&gt; 
  &lt;p&gt;Agent NPN: &lt;input data-bind='value: NPN' /&gt;&lt;/p&gt;
  &lt;p&gt;Lead Location: &lt;input data-bind='value: leadlocation' /&gt;(City, State, Zip)&lt;/p&gt;
  &lt;p&gt;Requested Lead Delivery Time/Date: &lt;/p&gt;
      &lt;p&gt;&lt;input data-bind='value: leaddeliverytime' /&gt;&lt;/p&gt;
  &lt;p&gt;Leads Requested: &lt;select&gt;
  &lt;option value="1"&gt;1&lt;/option&gt;
  &lt;option value="2"&gt;2&lt;/option&gt;
  &lt;option value="3"&gt;3&lt;/option&gt;
  &lt;option value="4"&gt;4&lt;/option&gt;
      &lt;option value="5"&gt;5&lt;/option&gt;
      &lt;option value="10"&gt;10&lt;/option&gt;
      &lt;/select&gt; &lt;/p&gt;
  &lt;p&gt;Email Address: &lt;input data-bind='value: EmailAddress' /&gt;&lt;/p&gt;
  &lt;/div&gt;
  &lt;div&gt;
          &lt;input type="button" id="btnSubmit" 
            value="Submit" data-bind = "click: submit" /&gt;
           &lt;input type="button" id="btnReset" 
             value="Reset" data-bind = "click: reset" /&gt;
      &lt;/div&gt;
  </code></pre>
  
  <p>script </p>
  
  <pre><code> var ViewModel = function(first, last, NPN, leadlocation, leaddeliverytime, EmailAddress) {
  this.firstName = ko.observable(first);
  this.lastName = ko.observable(last);
  this.NPN = ko.observable(NPN);
  this.leadlocation = ko.observable(leadlocation);
  this.leaddeliverytime = ko.observable(leaddeliverytime);
  this.EmailAddress = ko.observable(EmailAddress);
  
  };
  var jsonData = ko.toJson(viewModel);
  </code></pre>