/* This script and many more are available free online at
The JavaScript Source!! http://javascript.internet.com
Created by: Sandeep Gangadharan | http://www.sivamdesign.com/scripts/ */

function changer(link) {
  if (link=="") {
    return; }

//======================
// Edit this portion below. For each new state copy and paste
// the entire IF statement and change the name of the state and the cities.
// Make sure the spelling of the state is the same in the IF statement and in the link.

  if (link=="Level1") {
    document.theForm.AALevel.value="Level1";
    var theOptions=new Array (
"Southern Closed 10",
"Southern Closed 12",
"Southern Closed 14",
"Southern Closed 16",
"Southern Closed 18"); }
  else if (link=="Level2") {
    document.theForm.AALevel.value="Level2";
    var theOptions=new Array (
"Southern Spring Closed",
"Fall Southern Closed",
"Winter Southern Closed – Louisville",
"Winter Southern Closed – Knoxville",
"Southern Open 12",
"Southern Open 14",
"Southern Open 16",
"Southern Open 18",
"BullFrog – Jackson",
"BullFrog – Macon",
"BullFrog - Collins Hill",
"BullFrog -Little Rock",
"BullFrog – Marietta",
"BullFrog – Memphis",
"BullFrog - Hilton Head",
"BullFrog – Clemson",
"BullFrog - Baton Rouge",
"BullFrog – Cary",
"BullFrog – Raleigh",
"BullFrog – Mobile"); }
  else if (link=="Level3") {
    document.theForm.AALevel.value="Level3";
    var theOptions=new Array (
"KRC Mid Winter",
"Dasani Mayor's Cup",
"One Love Tennis Jr. Champs",
"'9'th Annual Midcourt Cup",
"Blue Gray Jr. Classic",
"Polar Bear Jr. Classic Open",
"Thornblade Jr. Tennis Classic",
"Southern States Top 32",
"Topspin Annual Jr. Classic",
"Louisiana Spring State",
"Alabama Jr. State Spring Clay",
"North Hills Club Spring Open",
"Aquafina MS Jr Open",
"Pepsi Junior Open – Florence",
"Arkansas Jr. State Qualifying",
"Peach State",
"Alabama Jr. State Spring Hard Court",
"Alabama Jr. State Qualifying",
"Georgia State Jr. Closed Qualifying",
"Joe Creason KY State Jr. Qualifier",
"Louisiana State Closed Jr. Qualifying",
"MS Cabot Lodge Jr. Qualifying",
"NC State Tar Heel Qualifier",
"TN State Jr Qualifying 16 – 18",
"TN State Jr Qualifying 12 – 14",
"Wachovia Palmetto State Qualifer",
"GA State Jr. Open",
"String N Swing Tennis Junior Classic"); }


// Do not edit anything below this line:
//======================

  i = document.theForm.ABTournamentName_r.options.length;
    if (i > 0) {
      document.theForm.ABTournamentName_r.options.length -= i; document.theForm.ABTournamentName_r.options[i] = null;
    }

  var theCount=0;
  for (e=0; e<theOptions.length; e++) {
    document.theForm.ABTournamentName_r.options[theCount] = new Option();
    document.theForm.ABTournamentName_r.options[theCount].text = theOptions[e];
    document.theForm.ABTournamentName_r.options[theCount].value = theOptions[e];
    theCount=theCount+1; }
}

//  NOTE: [document.theForm.theState.value] will get you the name of the state,
//  and [document.theForm.ABTournamentName.value] the name of the city chosen


