// JavaScript Document
function checkuser(){
document.formcheck.submit();
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

//Important functions for select boxes
var ajax = new sack();

function getCityList(sel)
{
	var models = sel.options[sel.selectedIndex].value;
	document.getElementById('models').options.length = 0;	// Empty city select box
	if(models.length>0){
		ajax.requestFile = 'getmodels.php?models='+models;	// Specifying which file to get
		ajax.onCompletion = createCities;	// Specify function that will be executed after file has been found
		ajax.runAJAX();		// Execute AJAX function
	}
}

function createCities()
{
	var obj = document.getElementById('models');
	eval(ajax.response);	// Executing the response from Ajax as Javascript code	
}
