function Go(link)
{
    document.location=link;
	return true;
}

function CGo(link, mesg)
{
    if (confirm(mesg))
	{
		document.location=link;
		return true;
	}
}

function _v(id)
{
    return document.getElementById(id);
}
function Show(img, w, h)
{
    if (!w)
	{
	    w = 100;	
	}
	if (!h)
	{
	    h = 100;	
	}
	window.open('/lite/showimg.php?img='+img,'popup','resizable=1,left=0,top=0, width='+w+', height='+h+', scrollbars=yes'); 	
}

function ShowT(id) {
    w = 400;	
    h = 500;	
	window.open( '/lite/st.php?id='+id,'popup','resizable=1,left=0,top=0, width='+w+', height='+h+', scrollbars=yes'); 	
}

function ShowV(id) {
    w = 400;	
    h = 500;	
	window.open( '/lite/vd.php?id='+id,'popup','resizable=1,left=0,top=0, width='+w+', height='+h+', scrollbars=yes'); 	
}

function getTags(wh) {
	var req = new JsHttpRequest();
    req.onreadystatechange = function() {
        
		if (req.readyState == 4) {
		    
			_v('v1').className   = (wh ? 'act' : '');
		    _v('v2').className   = (wh ? '' : 'act');			
            _v('tag').innerHTML  = req.responseJS.q;			
        }	
    }
    req.open(null, siteAdr+'ajax.php', true);
    req.send( { action: 'get_tags', wh: wh, lang: lang } );

}