title: jquery update total based on checkboxes
body: <p>I have a form where based on checkbox total value will be updated</p>
  
  <p>Here is my form</p>
  
  <pre><code>&lt;label class="checkbox"&gt;
          &lt;input type="checkbox" class="check" value="23"&gt;SEO                             
      &lt;/label&gt;
      &lt;label class="checkbox"&gt;
          &lt;input type="checkbox" class="check" value="34"&gt;XYZ 
      &lt;/label&gt;                                
      &lt;label class="checkbox"&gt;
              &lt;input type="checkbox" class="check" value="45"&gt;Logo Design                                  
      &lt;/label&gt;
  
  
      &lt;span class="product-price" id="total" &gt;45&lt;/span&gt;
  </code></pre>
  
  <p>jQuery I have used</p>
  
  <pre><code>  $('input[type=checkbox]').change(function () {
          var val = parseFloat(this.value),
              totalVal = parseFloat($('#total').val());
          if (this.checked) {
              $('#total').val((totalVal + val).toFixed(2));
          } else {
              $('#total').val((totalVal - val).toFixed(2));
          }
      });
  </code></pre>
  
  <p>But nothing get updated.What could be the possible Error?
  Any solution please</p>