function pick(obj) {
	obj.filters.alpha.opacity=100;
	obj.filters.gray.enabled=false;
}
function unpick(obj) {
	obj.filters.alpha.opacity=80;
	obj.filters.gray.enabled=true;
}
function customize(URL) {    
	//var address = URL + "&P=" + document.P.VT.value + "&PID=$ID";
	var address = URL;
	var op_tool  = 0;    
	var op_loc_box  = 0;    
	var op_dir  = 0;    
	var op_stat  = 0;    
	var op_menu  = 0;    
	var op_scroll  = 1;    
	var op_resize  = 0;    
	var op_wid  = 500;   
	var op_heigh = 450;                 
	var option = "toolbar="+ op_tool +",location="+ op_loc_box +",directories=" 
	+ op_dir +",status="+ op_stat +",menubar="+ op_menu +",scrollbars="  
	+ op_scroll +",resizable="  + op_resize +",width=" + op_wid +",height="+ op_heigh;
	var win3 = window.open("", "what_I_want", option);  
	var win4 = window.open(address, "what_I_want");
}
function AddToCart(URL) {    
	//var address = URL + "&P=" + document.P.VT.value + "&PID=$ID";
	var address = URL;
	var op_tool  = 0;    
	var op_loc_box  = 0;    
	var op_dir  = 0;    
	var op_stat  = 0;    
	var op_menu  = 0;    
	var op_scroll  = 1;    
	var op_resize  = 0;    
	var op_wid  = 100;   
	var op_heigh = 50;                 
	var option = "toolbar="+ op_tool +",location="+ op_loc_box +",directories=" 
	+ op_dir +",status="+ op_stat +",menubar="+ op_menu +",scrollbars="  
	+ op_scroll +",resizable="  + op_resize +",width=" + op_wid +",height="+ op_heigh;
	var win3 = window.open("", "what_I_want", option);  
	var win4 = window.open(address, "what_I_want");
}

function echeck(str) {

		var at="@"
		var dot="."
		var lat=str.indexOf(at)
		var lstr=str.length
		var ldot=str.indexOf(dot)
		if (str.indexOf(at)==-1){
		   //alert("Invalid E-mail ID")
		   return false
		}

		if (str.indexOf(at)==-1 || str.indexOf(at)==0 || str.indexOf(at)==lstr){
		   return false
		}

		if (str.indexOf(dot)==-1 || str.indexOf(dot)==0 || str.indexOf(dot)==lstr){
		    return false
		}

		 if (str.indexOf(at,(lat+1))!=-1){
		    return false
		 }

		 if (str.substring(lat-1,lat)==dot || str.substring(lat+1,lat+2)==dot){
		    return false
		 }

		 if (str.indexOf(dot,(lat+2))==-1){
		    return false
		 }
		
		 if (str.indexOf(" ")!=-1){
		    return false
		 }

 		 return true					
	}

function ValidateForm(){
	var emailID=document.F.email
	
	if ((emailID.value==null)||(emailID.value=="")){
		return false
	}
	if (echeck(emailID.value)==false){
		return false
	}
	return true
 }

function checkContact()	{
	var miss = false
	for (i=1; i<=5; i++)
	{
		if (document.getElementById('C_' + i).value.length < 1)
		{
			miss = true
			document.getElementById('CE_' + i).style.display = 'block'
		}
		else	{
			document.getElementById('CE_' + i).style.display = 'none'
		}
	}
	if (ValidateForm())
	{
		document.getElementById('CE_6').style.display = 'none'
	}
	else	{
		document.getElementById('CE_6').style.display = 'block'
		miss = true
	}
	if (miss == false)
	{
		F.submit();
	}
}
