var idReloadTimer = 0;
var BasketIFrame = 0;
var BasketWindow;

function BasketPopupWindow(URL, form){
	BasketWindow=window.open (URL + '&Qty=' + form.Qty.value + '&confirm=yes', 'basket', 'width=350, height=200, scrollbars=0');
	if(BasketWindow==0)
	    return true;
	return false;
}

function ShowBasketWindow(URL, form){
    BasketIFrame = document.getElementById("ShortBasket");
    var BasketInES = false;
    if(BasketIFrame){
	    BasketInES = true;
    }
    if(BasketInES){
	BasketIFrame.src=URL + '&Qty=' + form.Qty.value;
	var cmd="ReloadIFrame()";
	idReloadTimer=window.setTimeout(cmd, 500);
    }else{
	BasketWindow=window.open (URL + '&Qty=' + form.Qty.value, 'basket', 'width=350, height=200, scrollbars=0');
	if(BasketWindow==0)
	    return true;
    }    
    return false;
}
function SubmitLangForm(lang){
    var Form = document.forms.LanguageForm;
    if(Form){
	Form.elements["lang"].value=lang;
	Form.submit();
    }
}
function closeParentWindows(){
    return;
}

function ShowOrderFact(item, cookie){
    if(item.src){
        imagesubmit = item;
        item.src="/Images/i_basket1.gif";
    }
}
