function loadRatesIntoControl(){
	var el;
	
	var ctrl = document.getElementById("ctrlRates");
	el = document.createElement("OPTION");
	
	el.appendChild( document.createTextNode( "Select Rate"));
	
	ctrl.appendChild(el);
	
	for(var i=0; i< rates.length; i++){
		el = document.createElement("OPTION");
		el.appendChild( document.createTextNode( rates[i][0]));
		el.value = rates[i][1];
		ctrl.appendChild(el);
	
	}
	
	ctrl.onchange=function(){
		document.getElementById("rateValue").innerHTML = this.options[ this.selectedIndex].value;
	}
}

window.onload = function(){

	loadRatesIntoControl();

}
