
function doImagePopup(img)
{
	var wHnd = null;
	wHnd = window.open('imagePopup.aspx?img=' + img + '&dir=1','null',"width=20,height=20,left=20,top=20,resizable=yes,status=no,scrollbars=no");
	return false;
} 
		
function doPageText(partno)
{
	var wHnd = null;
	wHnd = window.open('ProductText.aspx?partno=' + partno + '&dir=1','null',"width=600,height=680,left=10,top=10,resizable=yes,status=no,scrollbars=yes");
	return false;
}

function doPageSettings(catid)
{
	var wHnd = null;
	wHnd = window.open('PageSettings.aspx?catid=' + catid + '&dir=1','null',"width=670,height=700,left=10,top=10,resizable=yes,status=no,scrollbars=yes");
	return false;
} 

function doFileDownload(filename)
{
 newWindow('files/' + filename,'windowFileDownload')
}

function newWindow(file,window,width,height) 
{
	var msgWindow=open(file,window,'resizable=yes,width=' + width + ',height=' + height + ',scrollbars=yes');
	if (msgWindow.opener == null) msgWindow.opener = self;
}

function printPage()
{
	window.print()
}

function clickButton(e, buttonid){ 
	
	var bt = document.getElementById(buttonid); 
	if (typeof bt == 'object'){ 
			if(navigator.appName.indexOf("Netscape")>(-1)){ 
				if (e.keyCode == 13){ 
						bt.click(); 
						return false; 
				} 
			} 
			if (navigator.appName.indexOf("Microsoft Internet Explorer")>(-1)){ 

				if (event.keyCode == 13){ 
						bt.click(); 
						return false; 
				} 
			} 
	} 
} 
function toggle(DivID) 
{

   var obj = document.layers ? document.layers[DivID] :
   document.getElementById ?  document.getElementById(DivID).style :
   document.all[DivID].style;
   if (obj.display=="none"){
	obj.display = "block";}
   else{
	obj.display = "none";}

}