<!--
/*
	============================================================
	Basic fce
	============================================================
	Copyright: www.eastburger.cz (c) 2009 All rights reserved.
	============================================================
 	Spoluprace:
	------------------------------------------------------------
*/


function ConfirmWindow(sMsg){
	if(sMsg == '') sMsg = lgCheckDeleteItem;
	else if(sMsg == 'del-items') sMsg = lgCheckDeleteItems;
	return confirm(sMsg);
}

function CreateLink(str3, str2, str1){
	atsign = '@';
	document.write('<a href="mailto:' + str1 + atsign + str2 + '.' + str3 + '">' + str1 + atsign + str2 + '.' + str3 + '</a>');
}

function GoToPage(theElement, sUrl, sUrlEnd){
	window.location.href = sUrl+theElement.value+sUrlEnd;
}

function CharCounter(theElement, maxLength, charInElement, charRemainElement){
	msgLength = theElement.value.length;
	if (msgLength > maxLength){
		theElement.value = theElement.value.substring(0,maxLength);
		msgLength = theElement.value.length;
	}
	else{
		document.getElementById(charInElement).value = msgLength;
		document.getElementById(charRemainElement).value = (maxLength - msgLength);
	}
} 

function NewWindow(theElement){
	var objWnd = window.open(theElement.href);
	objWnd.focus();
}

function SetTr(theElement, theAction){
	if(theAction == 'over'){
		if(theElement.className != 'tr-click') theElement.className = 'tr-over';
	}
	else if(theAction == 'out'){
		if(theElement.className != 'tr-click') theElement.className = '';
	}
	else if(theAction == 'click'){
		if(theElement.className == 'tr-click') theElement.className = '';
		else theElement.className = 'tr-click';
	}
}

//-->