<!--
var primariesName	= new Array();
var primaries		= new Array();
var secondaries		= new Array();

function doList(listBox)
{
	with (document.forms[0])
	var selectedItem = listBox.selectedIndex;
	if(selectedItem != -1)
	{
		selectedPrimary(new String(listBox.options[selectedItem].value));
	}
}
function P(priNum, priVal)
{
	primariesName[priVal] = new PrimariesName(priVal,priNum);
	primaries[priNum] = new Primary(priVal,priNum);
}
function S(priNum, secVal)
{
	primaries[priNum].secondaries[secVal] = new Secondary(secVal, priNum);
}
function Primary(priVal,priNum)
{
	this.primaryValue = priVal;
	this.primaryNumber = priNum;
	this.secondaries = new Array();
}
function Secondary( secVal,secNum )
{
	this.secondaryValue = secVal;
	this.primaryNumber = secNum;
}
function PrimariesName(priVal,priNum)
{
	this.primaryNumber = priNum;
}
function fillSecondarySelect( nPrimary )
{
	if (nPrimary == null){getSecondaryList().options.length=0;return;}

	if (getPrimaryList().options.selectedIndex == 0){getSecondaryList().options.length = 0;}
	else
	{
		getSecondaryList().options.length = 1; 
		var selectedSecondaries = (primaries[nPrimary].secondaries);
		getSecondaryList().options[0] = new Option("Any Model","");
		var x=1;
		for ( index in selectedSecondaries )
		{
			oSecondary = selectedSecondaries[index];
			getSecondaryList().options[x] = new Option( oSecondary.secondaryValue, oSecondary.secondaryValue );
			
			x++;
		}
	}
}
function selectedPrimary( selectedPrimaryValue )
{
	var i = 0;var index;
	for (index in primariesName){if (index == selectedPrimaryValue){i++;}}
	if (i == 0){fillSecondarySelect(null);}
	else{fillSecondarySelect(primariesName[selectedPrimaryValue].primaryNumber);}
}
//-->
 