var dl,p,s,corn_innerlink,corn_oldonload,corn_cdtime,corn_buycd_timerID,uagent,is_opera,url,up,us;

if (0) {
 var _gaq = _gaq || [];
 _gaq.push(['_setAccount', 'UA-285326-42']);
 _gaq.push(['_trackPageview']);
 _gaq.push(['t2._setAccount', 'UA-285326-30']);
 _gaq.push(['t2._trackPageview']);
 (function(){
  var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
  ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
  var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
 })();
}


url=String(document.location);
up=url.lastIndexOf('?');
if (up<0) us=''; else us='-'+url.substring(up+1,url.length).toLowerCase();

//document.write('<table cellspacing=0 cellpadding=0 border=0 height=62 width=790 align=center><tr><td height="48" width="180" bgcolor="#E7E7E7"><noindex><a href="http://www.tut.by/"><img src="http://www.tut.by/images/logo.hat.gif" width="180" height="48" border="0" alt="TUT.BY"></a></td><td rowspan="2" valign="bottom" bgcolor="#E7E7E7" height="62" width="100%"><iframe src="http://www.tut.by/bannerz/468.html" width=468 height=60 marginwidth=0 marginheight=0 scrolling="no" frameborder=0></iframe><br><img src="http://www.tut.by/images/bot.hat.gif" width="125" height="3" border="0" alt=""></td></tr><tr><td align="center" height="22" bgcolor="#ffffff"><table border="0" cellspacing="0" cellpadding="0"><tr><form style=margin:0px;padding:0px><td style="font-size: 14px; font-weight: bold; color: #284E80;"><select onchange=top.location.href=this.options[this.selectedIndex].value style="width:154px;font-size: 12px; color: #284E80;"><option selected value=#>- ресурсы портала -<option value="http://mail.tut.by">Почта<option value="http://catalog.tut.by">Каталог<option value="http://pogoda.tut.by">Погода<option value="http://jobs.tut.by">Работа<option value="http://blogs.tut.by">Блоги<option value="http://forums.tut.by">Форумы<option value="http://tourism.tut.by">Туризм<option value="http://realty.tut.by">Недвижимость<option value="http://horo.tut.by">Гороскопы<option value="http://flowers.tut.by">Комнатные растения<option value="http://afisha.tut.by">Афиша</option><option value="http://torg.tut.by">Аукционы<option value="http://radio.tut.by">Радио<option value="http://finances.tut.by">Финансы<option value="http://spravka.tut.by">Справка<option value="http://referats.tut.by">Рефераты<option value="http://shop.tut.by">Магазины<option value="http://tv.tut.by">Телевидение<option value="http://ads.tut.by">Частные объявления<option value="http://Hoster.by">Хостинг ТУТ<option value="http://tutby.com/service/advert/">Интернет-реклама ТУТ<option value="http://www.tut.by/res.html">ВСЕ РЕСУРСЫ</select></form></tr></table></td></tr><tr><td height="3" bgcolor="#ffffff" colspan="2"><img src="http://tut.by/images/1x1.gif" width="1" height="1" border="0" alt=""><img src="http://globus.tut.by/_prg/c_main.php?gl'+us+'" width=1 height=1 alt=""><img src="http://counter.yadro.ru/hit?r'+escape(document.referrer)+((typeof(screen)=='undefined')?'':';s'+screen.width+'*'+screen.height+'*'+(screen.colorDepth?screen.colorDepth:screen.pixelDepth))+';'+Math.random()+'" width=1 height=1 alt=""><a href="http://top100.rambler.ru/top100/"><img src="http://counter.rambler.ru/top100.cnt?472877" alt="" width=1 height=1 border=0></a></noindex></td></tr></table>');

document.write('<img src="http://counter.yadro.ru/hit?r'+escape(document.referrer)+((typeof(screen)=='undefined')?'':';s'+screen.width+'*'+screen.height+'*'+(screen.colorDepth?screen.colorDepth:screen.pixelDepth))+';'+Math.random()+'" width=1 height=1 alt=""><a href="http://top100.rambler.ru/top100/"><img src="http://counter.rambler.ru/top100.cnt?472877" alt="" width=1 height=1 border=0></a>');

corn_oldonload=document.body.onload;
document.body.onload=corn_onLoad;

corn_cdtime=-1;
//corn_cdtime=1;
corn_buycd_timerID=0;

uagent=navigator.userAgent.toLowerCase();
is_opera=(uagent.indexOf('opera') != -1);

corn_innerlink='';
dl=""+document.location; //document["location"];
p=dl.lastIndexOf('#');
if (p<0) s=''; else s=dl.substring(p+1,dl.length).toLowerCase();
corn_innerlink=s.toLowerCase();
document.write('<span id=cdcorner_id style="position:absolute; left:0px; top:0px; z-index:99; visibility:hidden;"><TABLE id=ii1 name=tt1 cellspacing="0" cellpadding="0" border="0" bgcolor="#000000" width=160><tr><td><TABLE id=ii2 name=tt2 cellspacing="1" cellpadding="3" border="0" width=100%><tr><td bgcolor=#c4c4c4 style="font-size:8pt; color:#555555;" align=center>Медленно загружается?<br><a href=http://globus.tut.by/buy.htm>Купите</a> этот сайт на DVD.</table></table></span>');

function corn_onLoad()  { 
document.all.cdcorner_id.style.visibility='hidden';
if (corn_oldonload==null) {} else corn_oldonload();
clearTimeout(corn_buycd_timerID);
corn_buycd_timerID=0;
}

function corn_frombottom() {
if (corn_cdtime>0) corn_buycd_timerID=setTimeout("corn_buycd_show()",corn_cdtime);
}

function corn_buycd_show()  {
var i,el,elfound,nx,ny,eltop,elleft;

clearTimeout(corn_buycd_timerID);
elfound=null;
for (i=0; i<document.anchors.length; i++) {
	el=document.anchors[i];
	if (el.name.toLowerCase()==corn_innerlink) {
		//document.write(' [EQU '+i+' ('+s+')] ');
		elfound=el;
		break;
	}
}

if (elfound==null || is_opera || elfound.name=='pagetop') { el=document.body; eltop=-1000; elleft=-1000; }
else { 
	el=elfound; 
	eltop=corn_getPos(el,"Top"); 
}

ny=eltop+2;
if (ny<0) ny=2;
nx=2;
document.all.cdcorner_id.style.top=ny+document.body.clientHeight-37;
document.all.cdcorner_id.style.left=nx;
document.all.cdcorner_id.style.visibility='visible';
}

function corn_getPos(el,sProp) {
	var iPos = 0;
	while (el!=null) {
		iPos+=el["offset" + sProp]
		el = el.offsetParent
	}
	return iPos
}


