function buildingSubSectionFunction()
{
  var buildingOlderThan35Years = document.commercialQuoteForm.buildingOlderThan35Years[0].checked;
  if (buildingOlderThan35Years == true)
  {
    document.getElementById('buildingSubSection').style.display = 'block';
	document.getElementById('buildingSubSectionTable').style.display = 'block';	
  }
  else
  {
    document.getElementById('buildingSubSection').style.display = 'none';
	document.getElementById('buildingSubSectionTable').style.display = 'none';
  }
}

function hasSprinklerFunction()
{
  var hasSprinkler = document.commercialQuoteForm.hasSprinkler[0].checked;
  if (hasSprinkler == true)
  {
    document.getElementById('percentSprinkledSubSection').style.display = 'block';
  }
  else
  {
    document.getElementById('percentSprinkledSubSection').style.display = 'none';
  }
}

function hasBasementFunction()
{
  var hasBasement = document.commercialQuoteForm.hasBasement[0].checked;
  if (hasBasement == true)
  {
    document.getElementById('basementSubSection').style.display = 'block';
  }
  else
  {
    document.getElementById('basementSubSection').style.display = 'none';
  }
}

function hasOilTankFunction()
{
  var hasOilTank = document.commercialQuoteForm.hasOilTank[0].checked;
  if (hasOilTank == true)
  {
    document.getElementById('ageOfOilTankSubSection').style.display = 'block';
  }
  else
  {
    document.getElementById('ageOfOilTankSubSection').style.display = 'none';
  }
}

function hasAlarmSystemFunction()
{
  var hasAlarmSystem = document.commercialQuoteForm.hasAlarmSystem[0].checked;
  if (hasAlarmSystem == true)
  {
    document.getElementById('ULCApprovedSubSection').style.display = 'block';
	document.getElementById('alarmSystemTypeSubSection').style.display = 'block';
  }
  else
  {
    document.getElementById('ULCApprovedSubSection').style.display = 'none';
    document.getElementById('alarmSystemTypeSubSection').style.display = 'none';
  }
}

function profLiabilityReqFunction()
{
  var profLiabilityReq = document.commercialQuoteForm.profLiabilityReq[0].checked;
  if (profLiabilityReq == true)
  {
    document.getElementById('profLiabilityReqSubSection').style.display = 'block';
  }
  else
  {
    document.getElementById('profLiabilityReqSubSection').style.display = 'none';
  }
}

function changeImage(img_name, img_src) {
  document[img_name].src = img_src;
}
