<!--
// ©2004 Vady
// language actions

function _setLang(lng) {
	var today = new Date();
	var expires = new Date();
	expires.setTime(today.getTime() + 1000*60*60*1);
	//setCookie("LANG", "text text text", expires);
	document.cookie = "LANG="+escape(lng)+";expires="+expires.toGMTString();
}

function _readLang(name) {
	if (name == null) name = 'LANG';
	var firstChar, lastChar, _value;
	var theBigCookie = document.cookie;

	firstChar = theBigCookie.indexOf(name);
	if (firstChar != -1) {
		firstChar += name.length + 1;
		lastChar = theBigCookie.indexOf(';', firstChar);
	if (lastChar == -1) lastChar = theBigCookie.length;
		_value = theBigCookie.substring(firstChar, lastChar);
	}
	return _value;
}

if(_readLang() == 'undefined' || _readLang() == null) {
	_setLang('ru');
}

//-->
