function validator()
{
	var good, j;
		good = false;
		for (j = 0; j < document.appfinder.cat.length; j++) {
				if (document.appfinder.cat[j].checked) {
					good = true;
				}
		}
		if (good == false) {
			alert("You must select one or more types of apparel from the orange boxes.");
			return false;
		}
	if (document.appfinder.scode_color.selectedIndex != 0) {
		if (document.appfinder.scode_size.selectedIndex == 0) {
			alert("To use the color option, you must also select your size.");
			return false;
		}
	}
}
function setImage (imgName, pcode)
{
	document.images[imgName].src = "http://img.runningwarehouse.com/ProductImages/" + pcode + ".JPG";
}
function setThumbImage(imgId, info){
  document.getElementById(imgId).src = "http://img.runningwarehouse.com/thumbs/"+info+"-thumb.jpg";
}
function rollover (imgName, pcode, number)
{
	document.images[imgName].src = "http://img.runningwarehouse.com/shoeviews/" + pcode + "-" + number + ".jpg";
}

function setLargeImage (imgName, pcode)
{
	document.images[imgName].src = "http://img.runningwarehouse.com/big/" + pcode + "-big" + ".jpg";
}
function setHref (pcode, color)
{
	document.anchors[0].href= "http://www.runningwarehouse.com/viewlarge.html?pcode=" + pcode + "&large=" + color;
	document.anchors[1].href= "http://www.runningwarehouse.com/viewlarge.html?pcode=" + pcode + "&large=" + color;
	document.anchors[2].href= "http://www.runningwarehouse.com/viewlarge.html?pcode=" + pcode + "&large=" + color;
	document.anchors[3].href= "http://www.runningwarehouse.com/viewlarge.html?pcode=" + pcode + "&large=" + color;
}
function chooseone(form, element, error){
	alert(form.element.value)
	if (form.elements[element].value==''){
		alert(error);
		return false;
	}else{
		return true;
	}
}
function enterqty(form, element, error){
	if ((form.elements[element].value=='') || (form.elements[element].value=='Qty')){
		alert(error);
		return false;
	}else{
		return true;
	}
}