function checkDisplay(field,container) {
	f = document.getElementById(field);
	c = document.getElementById(container);
	
	if(f == null || c == null) {
		return false;
	}
	 
	if(f.checked == true) {
		c.style.display = "block";	
	} else {
		c.style.display = "none";	
	}
}


function popUp(file,width,height) {

	height = parseInt(height);
	width = parseInt(width);
	popup = window.open('/popup.php?f='+file,'popup','width='+width+',height='+height);
}

function setStatus(str) {
	window.status = str;
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

var downStrokeField;
function autojump(fieldName,nextFieldName,fakeMaxLength)
{
var myForm=document.forms[document.forms.length - 1];
var myField=myForm.elements[fieldName];
myField.nextField=myForm.elements[nextFieldName];

if (myField.maxLength == null)
   myField.maxLength=fakeMaxLength;

myField.onkeydown=autojump_keyDown;
myField.onkeyup=autojump_keyUp;
}

function autojump_keyDown()
{
this.beforeLength=this.value.length;
downStrokeField=this;
}

function autojump_keyUp()
{
if (
   (this == downStrokeField) && 
   (this.value.length > this.beforeLength) && 
   (this.value.length >= this.maxLength)
   )
   this.nextField.focus();
downStrokeField=null;
}
