title: How to add two values from range slider to form a single value
body: <p>I'm working on some code that adds two values together to form a complete one. What I'm trying to get is the values from Bedrooms and Bathrooms to add to a single value. Each value is a numeric value, but I don't know how to combine them. Any help would be greatly appreciated. </p>
  
  <p>Here is the JS Fiddle. I'm not sure why it's not working. </p>
  
  <p><a href="https://jsfiddle.net/n48kvejy/22/" rel="nofollow noreferrer">https://jsfiddle.net/n48kvejy/22/</a></p>
  
  <pre><code>var basePrice = 85.00;
  
  function sliderChange(val) {
    document.getElementById('bed_display').innerHTML = val;
  }
  
  function sliderChange2(val) {
    document.getElementById('bath_display').innerHTML = val;
  }
  
  function changePrice(val) {
    if (val == 1) {
      document.getElementById('price').innerHTML = basePrice;
    }
    if (val == 2) {
      document.getElementById('price').innerHTML = basePrice + 10;
    }
    if (val == 3) {
      document.getElementById('price').innerHTML = basePrice + 35;
    }
    if (val == 4) {
      document.getElementById('price').innerHTML = basePrice + 70;
    }
    if (val == 5) {
      document.getElementById('price').innerHTML = basePrice + 95;
    }
    if (val == 6) {
      document.getElementById('price').innerHTML = basePrice + 120;
    }
  }
  
  function changePrice2(val) {
  
    if (val == 1) {
      document.getElementById('price').innerHTML = basePrice;
    }
    if (val == 2) {
      document.getElementById('price').innerHTML = basePrice + 25;
    }
    if (val == 3) {
      document.getElementById('price').innerHTML = basePrice + 50;
    }
    if (val == 4) {
      document.getElementById('price').innerHTML = basePrice + 75;
    }
    if (val == 5) {
      document.getElementById('price').innerHTML = basePrice + 100;
    }
    if (val == 6) {
      document.getElementById('price').innerHTML = basePrice + 125;
    }
  }
  </code></pre>
  
  <p>I would like the code to do something similar to this: <a href="http://jsfiddle.net/humbleRumble/uL23spL1/1/" rel="nofollow noreferrer">http://jsfiddle.net/humbleRumble/uL23spL1/1/</a></p>
  
  <p>Thank you!</p>