function checkAll(thisForm,elmnt,tf,x) {
	var o = document.forms[thisForm].elements
	if (o){
		for (i=0; i<o.length; i++){
			if (elmnt != ''){
				if ((o[i].type == 'checkbox')&&(o[i].name.indexOf(elmnt+"") != -1)){
					o[i].checked = tf
				}
			}
			else {
				if (o[i].type == 'checkbox'){
					o[i].checked = tf
				}
			}			
		}
	}	
	for (var j = 0; j < document.links.length; j++){
		if ((document.links[j].href.indexOf(thisForm) != -1) && (document.links[j].href.indexOf('checkAll') != -1)){
			if (tf == true){
				document.links[j].href = "javascript:checkAll('"+thisForm+"','"+elmnt+"',false)";
				//document.links[j].innerText = "- all";
			}
			else {
				document.links[j].href = "javascript:checkAll('"+thisForm+"','"+elmnt+"',true)";
				//document.links[j].innerText = "+ all";
			}
		}
	}
}

function openWindow(pageName,pageWidth,pageHeight) {

window.open(pageName,"remote","width=" + pageWidth + " ,height=" + pageHeight + ",menubar=no");

}