<!--
  var txtQ = new Array();
  var rating=0;
  var ratingLevel=5;

  val = new String(location.search)
  type = val.substring(val.indexOf("type")+5,val.length)

  test = "influence";
  var txtAns = new Array(11);

  txtQ[1]  = "I convey confidence to others"
  txtQ[2]  = "I compliment people and make them feel special"
  txtQ[3]  = "I look for ways to offer hope to others"
  txtQ[4]  = "I listen to and understand the key people in my life"
  txtQ[5]  = "I know where I'm going and am taking someone with me"
  txtQ[6]  = "I see things from the perspective of others and lead them accordingly"
  txtQ[7]  = "I encourage others and lift them up"
  txtQ[8]  = "I help people become more successful"
  txtQ[9]  = "I provide community where people can feel close to one another"
  txtQ[10] = "I model for others a good example to follow"

  document.write (openTable);

  for (n=1;n<txtAns.length;n++) {
    document.write (openRow + openCell + n + "." + closeCell + "\n");
    document.write (openCell + openSelect + "q" + n + " onChange=setAns(" + n + ",document.form.q" + n + ".selectedIndex)>\n");
    document.write ("\t" + openOption + "0 selected>Choose" + closeOption + "\n");

    for (m=1;m<ratingLevel+1;m++) document.write ("\t" + openOption + m + ">" + m + closeOption + "\n");

    document.write ("    " + closeSelect + "\n");
    document.write (closeCell + "\n");
    document.write (openCell + txtQ[n]);
    document.write (closeCell + closeRow + "\n");
  }

  document.write (closeTable);

  function resetAns() {
    for (n=1;n<txtAns.length;n++) {
	 txtAns[n] = 0;
    }
  }

  function setAns(q,val) {
    txtAns[q]=val;
    //alert("txtAns["+q+"]="+txtAns[q])
  }

  function validateFrm() {
    if (evalComplete()) {
      loc = "leadership/results.asp?val=" + rating + "&test=" + test + "&level=" + ratingLevel + "&q=" + (txtAns.length-1);
      evalWin = window.open(loc,"newwindow","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=no,resizable=0,width=300,height=320");
      evalWin.focus();
      document.location="evaluate.asp";
      return false;
    }
    else {
      return false;
    }
  }

  function evalComplete() {
    var num=0;
    sum=0;

    for (n=1;n<txtAns.length;n++) {
       if (txtAns[n] == 0) {
         alert ("Please enter a number from 1 to " + ratingLevel + " for question #" + n);
	 return false;
       }
       else sum+=txtAns[n];
    }

    if (sum > 0) {
      rating = Math.round(sum/txtAns.length);
      if (type > 10) alert ("Your leadership level is: " + rating);
      else alert ("Your influence level is: " + rating);
      return true;
      }
    else
      return false;
  }
// -->
