function expandTA(id, expRows) {
	if(!document.getElementById(id).rowsBefore) document.getElementById(id).rowsBefore = expRows;
	man = document.getElementById(id).rows;
	document.getElementById(id).rows = document.getElementById(id).rowsBefore;
	document.getElementById(id).rowsBefore = man;
}

function go(link) {
	document.location = link;
}

function popup(link, width, height) {
	var left = (screen.width - width - 20) / 2;
	var top = (screen.height - height - 30) / 2;
	var date = new Date();
	var sName = 'win' + date.getHours() + date.getMinutes() + date.getSeconds();
	window.open(link, sName, 'width='+width+',height='+height+',left='+left+',top='+top+',toolbar=no,location=no,status=no,resizable=yes,scrollbars=yes');
	return false;
}

function hideOnCheck(obj, div, value) {
	var o = document.getElementById(div);
	if (obj.checked && (obj.value == value)) o.className = ''; else o.className = 'hide';
}

function hide(div) {
	var o = document.getElementById(div);
	if(o.className=='') o.className = 'hide'; else o.className = '';
}

function showPicture(url, divDest, thickbox, loaded) {
	cod = "<img src=\""+url+"\"/>";
	if(thickbox) cod = "<a href=\""+thickbox+"\" class=\"thickbox\">"+cod+"</a>";
	document.getElementById(divDest).innerHTML=cod;
	if(loaded) tb_init('a.thickbox, area.thickbox, input.thickbox');
	return;
}

function un_check(obj, excep) {
	for (var i = 0; i < obj.elements.length; i++) {
		var e = obj.elements[i];
		if ((e.name != 'checkAll') && (e.type == 'checkbox')) {
			e.checked = obj.checkAll.checked;
		}
	}
}
