
 

function sendToLocator (){

	STORESORPLAY = "stores"
	
	var chosen = ""
	var len = document.form2.loctype.length
	for (i = 0; i <len; i++) {
		if (document.form2.loctype[i].checked) {
			chosen = document.form2.loctype[i].value
		}
	}
	if (chosen != "") {
		STORESORPLAY = chosen
	}

	var LOCATIONSEARCH = escape(document.form2.locsearch.value);
	if (LOCATIONSEARCH == "") {
		LOCATIONSEARCH = "Wizards of the Coast"
	}
	
//	var LOCATIONSEARCH = escape("Seattle & WA");
//	var STORESORPLAY = "buy" /// buy or play
 
	
	if (STORESORPLAY == "buy") { 
	
 	var locationURL = 'http://ww2.wizards.com/StoreAndEventLocator/Default.aspx?link=true&ReturnParamMapZoom=10&ReturnParamMapSearch=' + LOCATIONSEARCH + '&ReturnParamMode=buy&ReturnParamCheckedProducts=D%26D%3B&ReturnParamCheckedEvents=1%3A45%2C1%3A57%3B1%3A9%3B1%3A133%2C1%3A25%2C1%3A201%2C1%3A12%2C1%3A197%2C1%3A50%2C1%3A51%2C1%3A150%2C1%3A194%2C1%3A198%2C1%3A56%2C1%3A158%2C1%3A199%2C1%3A11%3B3%3A203%3B3%3A191%2C3%3A202%3B3%3A190%2C3%3A193%3B&ReturnParamCheckedEventBrands=3%3Ax%3B';

	} else {
	
 	var locationURL ='http://ww2.wizards.com/StoreAndEventLocator/Default.aspx?link=true&ReturnParamMapZoom=10&ReturnParamMapSearch=' + LOCATIONSEARCH + '&ReturnParamMode=play&ReturnParamCheckedProducts=D%26D%3B&ReturnParamCheckedEvents=40%3A203%2C40%3A205%3B40%3A202%3B40%3A193%3B&ReturnParamCheckedEventBrands=40%3Ax%3B&ReturnParamTablePage=0&ReturnParamLastDirectionsQuery=null'	
	
	}
	
	window.open(locationURL,'','');
 
} 
