function table_back(x,y) {
	document.getElementById('table_'+x).style.background="#"+y;
}
function menus_back(lvl,x,color,font) {
	document.getElementById('table_'+lvl+'0'+x).style.background='#'+menus_design[lvl][color];
	document.getElementById('table_'+lvl+'0'+x).className=menus_design[lvl][font];
}
function menus_link(lvl,x) {
	document.location.href=menus[lvl][x][1];
}
function lang_onclickAction(x) {	
	document.location.href = x;
}

function showHideComments(x,y) {
	if (y==1) { document.getElementById(x).style.visibility='visible'; }
	if (y==0) { document.getElementById(x).style.visibility='hidden'; }
}

var allowed_lvl=0;
function allow_create_lvl() {
	allowed_lvl=1;
	create_menu();
	create_containers();
	create_lvl('script');
}
function call_create_lvl() {
	if (allowed_lvl!=0) {
		allowed_lvl=3;
	}
}
function wait_till_create_lvl() {
	if (allowed_lvl>0) {
		allowed_lvl--;
		if (allowed_lvl==1) { create_lvl('page'); }
	}
}
window.setInterval('wait_till_create_lvl()',500);

function linkTo(x) {
	document.location.href=x;	
}
////////////////////////////////////////////////////

function scrolling_news() {
if (scrollings) {
	for (w=1; w<=scrollings[0];w++) {
	if (document.getElementById(scrollings[w]['div'])) {
		if (((scrollings[w]['currentPos']/scrollings[w]['newsH'])==(Math.round(scrollings[w]['currentPos']/scrollings[w]['newsH'])))&&(scrollings[w]['newsWaitC']<scrollings[w]['newsWait'])) {
			scrollings[w]['newsWaitC']++;
			if (scrollings[w]['newsWaitC']==scrollings[w]['newsWait']) { scrollings[w]['currentPos']++; scrollings[w]['newsWaitC']=0; }
		} else { scrollings[w]['currentPos']++; }
		if (scrollings[w]['currentPos']>scrollings[w]['totalH']) { scrollings[w]['currentPos']=1; }	
		document.getElementById(scrollings[w]['div']).style.top=-scrollings[w]['currentPos']; }
	}
	}
}
window.setInterval('scrolling_news()',1);

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}