<!--
var flag=false;
function DrawImagee(ImgD){
var image=new Image();
image.src=ImgD.src;
if(image.width>0 && image.height>0){
flag=true;
if(image.width/image.height>= 1){
if(image.width>310){ 
ImgD.width=310;
ImgD.height=(image.height*310)/image.width;
}else{
ImgD.width=image.width; 
ImgD.height=image.height;
}
}
else{
if(image.height>310){ 
ImgD.height=310;
ImgD.width=(image.width*310)/image.height; 
}else{
ImgD.width=image.width; 
ImgD.height=image.height;
}
}
}
} 


function peitu_view(str)
{
	var picture=document.getElementById("picture");
	picture.src=str;
	return false;	
}

function open_shopcare(str,kuchun)
{
	var jian=document.getElementById("jian");
	if(jian.value > kuchun)
	{
		alert("对不起,您选择的产品,库存不足！");
		return false;	
	}
	else
	{
		window.open (str+"&jian="+jian.value, 'newwindow', 'top=0, left=0, toolbar=no, menubar=no, scrollbars=yes, resizable=no,location=no, status=no');
	}
	return false;	
}

function open_shopcare2(str,kuchun)
{
	if(kuchun < 1)
	{
		alert("Sorry, your choice of goods, inventory shortage！");
		return false;	
	}
	else
	{
		window.open (str+"&jian=1", 'newwindow', 'top=0, left=0, toolbar=no, menubar=no, scrollbars=yes, resizable=no,location=no, status=no');
	}
	return false;	
}

//-->
