function submitForm() {
  <!-- check that q1 has been selected //-->
  var q1checked = false;
  for (i=0; i<document.quickPoll.q1.length; i++) {
    if (document.quickPoll.q1[i].checked) {
      q1checked = true;
    }
  }
  <!-- check that q2 has been selected //-->
  var q2checked = false;
  for (i=0; i<document.quickPoll.q2.length; i++) {
    if (document.quickPoll.q2[i].checked) {
      q2checked = true;
    }
  }
  <!-- if BOTH q1 and q2 are checked, submit form //-->
  if (q1checked && q2checked) {
	  quickPollWindow=window.open("","quickPollWindow","width=300,height=400,screenX=" + ((screen.width-300)/2) + ",screenY=" + ((screen.height-400)/2) + ",scrollbars=yes,resizable=yes")
	  quickPollWindow.creator=self;
	  document.quickPoll.target="quickPollWindow";
	  document.quickPoll.action="http://extension.umd.edu/nutrition/obesity/files/pollResults.cfm";
	  document.quickPoll.submit();
  }
}

function viewResults() {
  viewWindow=window.open("http://extension.umd.edu/nutrition/obesity/files/pollResults.cfm","viewWindow","width=300,height=400,screenX=" + ((screen.width-300)/2) + ",screenY=" + ((screen.height-400)/2) + ",scrollbars=yes,resizable=yes")
}