var cando = false;
var browserName = navigator.appName;
var browserVer = parseInt(navigator.appVersion);
if (browserName == "Netscape" && browserVer >= 3) cando = true;
else if( browserVer >=4 ) cando=true;
if( cando ) {
        imag = new Array();
        imag[0] = "img/m1.gif";
        imag[1] = "img/m12.gif";
        imag[2] = "img/m2.gif";
        imag[3] = "img/m22.gif";
        imag[4] = "img/m3.gif";
        imag[5] = "img/m32.gif";
        imag[6] = "img/m4.gif";
        imag[7] = "img/m42.gif";
	  imag[8] = "img/m5.gif";
        imag[9] = "img/m52.gif";	  
        im = new Array()
        for (var i = 0; i < imag.length; i++){
                if( imag[i] != "" ) {
                        im[i] = new Image();
                        im[i].src = imag[i];
                }
        }
}

function swtch(num,imgname){
        if( cando )
        eval("document.getElementById('"+imgname+"').src = im[num].src;");
}



function openpop(iname,img_width,img_height)
{
 var screen_width=screen.width;
 var screen_height=screen.height;
 var x=Math.round((screen_width/2)-(img_width/2));
 var y=Math.round((screen_height/2)-(img_height/2));
 y=y+50;

 window.open("popupimg.php?id="+iname+"&w="+img_width+"&h="+img_height+"","_blank","left="+x+",top="+y+",width="+img_width+",height="+(img_height+35)+",scrollbars=no");
 
}

$(function(){
    $("#productsandservices li.first-of-type").hover(function(){
        
		$(this).find("div.yuimenu").css({
            visibility: "visible"
        }).stop(true, true).slideDown("slow");
		
    }, function(){
        $(this).find("div.yuimenu").slideUp("slow")
    })
});
