﻿	function GetImage(SRC,Color)
	{
		document.it.MiddleImage.src=SRC
	}

	function popUp(ID)
	{
		window.location.href='ViewItem.aspx?ID='+ID
	}

	function sendemail(ID)
	{
		window.open('Pages/SendMail.aspx?ID='+ID,'mail','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=500,height=150');
	}

	function Sizes()
	{
		window.open('Pages/puSize.aspx','size','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=630,height=450')
	}
	
	function Tips()
	{
		window.open('Pages/puTips.aspx','tip','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=630,height=450')
	}
	
	function OOS()
	{
		window.open('Pages/puOutOfStock.aspx','ous','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=630,height=450')
	}

	function IsNumeric(sText)
	{
	   var ValidChars = "0123456789";
	   var IsNumber=true;
	   var Char;
	   for (i = 0; i < sText.length && IsNumber == true; i++) 
	      { 
	      Char = sText.charAt(i); 
	      if (ValidChars.indexOf(Char) == -1) 
	         {
	         IsNumber = false;
	         }
	      }
	   return IsNumber;
   }
	
	function checkZeroQuantities()
	{
		var selects;
		var select;
		var notZero;
		notZero = false;
		
		selects = document.getElementsByTagName('select');
		for (var i = 0; i < selects.length; i++) {
			select = selects[i];
			if (select.name.indexOf('selectQty_') == 0) {
				if(select.selectedIndex != 0){ 
					notZero = true; 
				}
				if(notZero){ break; }
			}
		}
		return notZero
			alert(notZero)
}
	
