var CurValuteName=''; // инициализируется вызовом из head.inc в функции Set_Check_And_Config
var CurValuteFlag='0'; // 0 - не установлен, 1-доллары, 2-рубли.
var	IDValute=CurValuteFlag;
var	DollarRateValueMax=1; // курс пересчета
var	CurCurse=DollarRateValueMax;
var scroll_pgn_num=1; // нумерация страниц для форумов
var	s_ch='';
var	s_cf='';
var RND=parseInt(Math.random()*100000);
var weight=0;
var index=0;
var IsIE = (window.navigator.appName.toLowerCase().indexOf('microsoft')!=-1)?true:false;
var IE_Ver = (window.navigator.appVersion.toLowerCase().indexOf('msie 7')!=-1)?7:6;

function show_img(width,height,s_url){
	var imgnwin=window.open(s_url,"imgswin","resizable=yes,scrollbars=yes,toolbar=yes,location=no,directoties=no,status=no,menubar=no,width="+width+",height="+height);
}

function show_bask(width,height,s_url){
	var basknwin=window.open(s_url,"baskswin","resizable=yes,scrollbars=yes,toolbar=no,location=no,directoties=no,status=no,menubar=no,width="+width+",height="+height);
}

function active_win(surl){
	window.opener.document.location=surl;
}

function show_div(id_cur){
    var div_set=null;
    div_set=document.getElementById(id_cur);
    if (div_set!=null) {
        if (div_set.style.display=="block") div_set.style.display="none";
        else div_set.style.display="block";
    }
}

function bright_cat_path(id_obj){
        var obj=document.getElementById(id_obj);
        if (obj!=null) obj.style.color="#83523a";
}

function Set_Check_And_Config(cur_valute_name,id_valute,valute_rate,valute_cash,checkhash,AutoCreateGoodsConfigurationsEnabled) {
	CurValuteName=cur_valute_name;
	CurValuteFlag=id_valute;
	IDValute=id_valute; // 0 - USD?, 1 - USD, 2 - RUR
	DollarRateValueMax=parseFloat(valute_rate); // курс пересчета
	CurCurse=DollarRateValueMax;
	s_ch=checkhash;
	s_cf=valute_cash;
	if (AutoCreateGoodsConfigurationsEnabled!='' && AutoCreateGoodsConfigurationsEnabled!='0') AutoCreateCfgFlag=true;
}


function w_send(){
	document.write('<input type=hidden name=s_ch value=\"'+s_ch+'\"><input type=hidden name=s_cf value=\"'+s_cf+'\">');
}
