	function doGetById(i) {
		var o = null;
		if (document.getElementById && document.getElementById(i) != null)
			o = document.getElementById(i);
		else if (document.layers && document.layers[i] != null)
			o = document.layers[i];
		else if (document.all)
			if (document.all[i] != null) {
				o = document.all[i];
			}
		return o;
	}
	
	function doSetClass(i, s) {
		var o = doGetById(i);
		o.className = s;
	}
	
	function doSetImage(i, s) {
		var o = doGetById(i);
		o.src = s;
	}
	
	function setDisplay(id, v) {
		if ( v==0 ) { v='none'; }
		if ( v==1 ) { v='block'; }
		if ( (v!='block') && (v!='none') ) { v==null }
			
		if (document.getElementById) {
			if (document.getElementById(id) != null) {
				if (v==null) {
					if (document.getElementById(id).style.display == "none") { v = 'block'; } 
					else { v = 'none'; }
				} document.getElementById(id).style.display = v;
			}
		} else { 
			if (document.layers) {	
				if ( v==null ) {
					if (document.id.display == "none"){ v = 'block'; } 
					else { v = 'none'; }
				} document.id.display = v;
			} else {
				if ( v==null ) {
					if (document.all.id.style.visibility == "none"){ v = 'block'; } 
					else { v = 'none'; }
				} document.all.id.style.display = v;
			}	
		}
		
		if (v == null) { return -1; }
		if (v == 'none') { return 0; }
		if (v == 'block') { return 1; }
		
	}
	
	
	function popup(page,w,h){
		mywindow = window.open (page,"mywindow","location=false,status=false,scrollbars=auto,width="+w+",height="+h);
		return mywindow;
	} 