﻿function onmouseshow(evt,wind,id)
{
     var  winWidth  =   0 ;
     var  winHeight  =   0 ;
     // 获得窗口宽度 
       if (window.innerWidth)   {
        winWidth  =  window.innerWidth;
    }   else   if ((document.body)  &&  (document.body.clientWidth))   {
        winWidth  =  document.body.clientWidth;
    } 

     // 获得窗口高度 
       if (window.innerHeight)   {
        winHeight  =  window.innerHeight;
    }   else   if ((document.body)  &&  (document.body.clientHeight))   {
        winHeight  =  document.body.clientHeight;
    } 

      if (document.documnetElement  &&  document.documnetElement.clientHeight  &&  document.documnetElement.clientWidth)   {
        winWidth  =  document.documnetElement.clientWidth;
        winHeight  =  document.documnetElement.clientHeight;
    } 
	var x=evt.clientX+wind.scrollLeft-10;
	var y=evt.clientY+wind.scrollTop+20;
	
	if ((winWidth-x)<250){x=x-200;}
	$("#showLayers").show();
	$("#showLayers").css("left",x+"px");
	$("#showLayers").css("top",y+"px");
	$.ajax({
		type: "GET",
		dataType: "text/json",
		url: "Ajax.ashx?Pid="+id,
		success:function(msg)
		{
		    var info = eval('('+msg+')');
	        $("#ShowContentImg").attr("src",info.ImgUrl);
	        $("#_title").html(info.Title);
	        $("#_price").html('配置:'+ info.ProductPeizhi);
		}
	}); 
}
function ClearImg()
{
	$("#ShowContentImg").attr("src","ajaximg/loading.gif");
	$("#showLayers").hide();
	
}