function bag_link(link) {
	document.location.href = link;
}

function winopen (popupURL,width,height) {
	var popup = window.open(popupURL,"popup",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=' + width + ',height=' + height + ',left=300' );
	popup.focus();
	if( navigator.appName.substring(0,8) == "Netscape" ) {
		popup.location = popupURL;
	}
}

function showBlock(blk){
       var agt = navigator.userAgent.toLowerCase();
       var is_bsd   = (agt.indexOf("bsd") != -1);
       var is_x11   = (agt.indexOf("x11") != -1);
       var is_linux = (agt.indexOf("linux") != -1);
       var is_mac   = (agt.indexOf("mac") != -1);
       obj = document.getElementById(blk).style;
       if ( is_bsd || is_x11 || is_linux || is_mac ) {
             obj.top = '20px';
       }
       obj.display = (obj.display != 'block' ? 'block' : 'none');
}

function hide(){
       obj = document.getElementById('audio').style.display = 'none';
       obj = document.getElementById('info').style.display = 'none';
       obj = document.getElementById('video').style.display = 'none';
       obj = document.getElementById('foto').style.display = 'none';
       //obj = document.getElementById('comment').style.display = 'none';
}



function sub_zakaz(){
    document.forms["pre_zakaz"].ac.value=0;
    document.forms["pre_zakaz"].submit();
}
function sub_del(id){
    document.forms["pre_zakaz"].ac.value=1;
    document.forms["pre_zakaz"].itemid.value=id;
    document.forms["pre_zakaz"].submit();
}
function sub_ch(){
    document.forms["pre_zakaz"].ac.value=2;
    document.pre_zakaz.submit();
}