// JavaScript Document


<!--
function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->







function submitcurrency(val)
{

    document.currency.action ="?action=setcurrency&curr="+val.value;
	document.currency.submit();
	


}




function SortBy(){

	var SortBy=document.getElementById('sort_by').value;
	//alert("sort_by=" + SortBy);
	if(SortBy=='price'){
	 document.getElementById('sort_order_name').style.display = "none"; 
	 document.getElementById('sort_order_price').style.display = "block"; 
	}
	else{
	 document.getElementById('sort_order_price').style.display = "none"; 
	 document.getElementById('sort_order_name').style.display = "block"; 
	}
}

function check_item(){

	var quantity=document.getElementById('quantity').value;
	var Price=document.getElementById('Price').value;
	//alert("sort_by=" + SortBy);
	if(quantity==''){
	alert(" :: Please enter quantity ::");
	return false;
	}
	
	if(Price==''){
	alert(" :: Please enter prduct type ::");
	return false;
	}
}

function my_wish_list(){


   
	var quantity=document.getElementById('quantity').value;
	var Price=document.getElementById('Price').value;
	//alert("sort_by=" + SortBy);
	
	if(quantity==''){
	alert(" :: Please enter quantity ::");
	return false;
	}
	
	if(Price==''){
	alert(" :: Please enter prduct type ::");
	return false;
	}
	
	//location.href='add_to_gift_list.php?PriceID='+Price+'&quantity='+quantity;
	location.href='my_gift_list.php?&todo=addToGiftList&PriceID='+Price+'&quantity='+quantity;
}



function address_book_check(){

	var CustomerID=document.getElementById('CustomerID').value;
	
	//alert("sort_by=" + SortBy);
	if(CustomerID==''){
	alert(" :: Please select any address ::");
	return false;
	}
	
}

function search_validation(){
	
	var search_by=document.getElementById('search_by').value;
	
	if(search_by==''){
	alert(" :: Please enter any search keywords ::");
	return false;
	}
	
}


function popup(){

//window.open("AddressBook.php");
window.open ("forgot_password.php","mywindow","location=1,status=1,scrollbars=1,width=600,height=400,top=100,left=150"); 

}



function test(obj1)
		{
		var str="no";
//		alert(obj1.value);
	var iChars = "!@#$%^&*()+=-[]\';,./{}|\":<>?";

  for (var i = 0; i < obj1.value.length; i++) {
//  alert(obj1.value.charAt(i));
  	if (iChars.indexOf(obj1.value.charAt(i)) != -1) 
  	{
	
//  	alert("Containts special characters. \n These are not allowed.\n Please remove them and try again.");


	str="yes";
	return str;
  	}
		
	 }	
	 }



var TotalMessage;
TotalMessage='';

function valid() {
//alert("HI");
  if(document.cust.FirstName.value=="") {
    //alert("First Name : Missing ");
	TotalMessage=TotalMessage+'First Name : Missing' + '\n';
	//document.cust.FirstName.focus();
	//return false;
  }
  
 if(document.cust.LastName.value=="") {
	//alert("Last Name  : Missing ");
	TotalMessage=TotalMessage+'Last Name : Missing' + '\n';
	//document.cust.LastName.focus();
	//return false;
  }
  
  //alert(TotalMessage);
  //TotalMessage='';
  //return false;
  
  
   if(document.cust.Email.value=="") {
   
   TotalMessage=TotalMessage+'E-Mail : Missing' + '\n';
   
    //alert("E-Mail : Missing ");
	//document.cust.Email.focus();
	//return false;
  }
 
  	if(document.cust.Email.value!="")
					{
					   var str=document.cust.Email.value;
					   var er=/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*\.(\w{2}|(com|net|org|edu|in|mil|gov|arpa|biz|aero|name|coop|info|pro|museum))$/;
					   if(!er.test(str))
					   {
					   	   TotalMessage=TotalMessage+'Please enter your valid email...' + '\n';
						   //alert ("Please enter your valid email...");
						   //document.cust.Email.focus();
						   //return false;
					   }
					}

  
 if(document.cust.BillingAddress1.value=="") {
 
     TotalMessage=TotalMessage+'Billing Address  : Missing' + '\n';
    //alert("Billing Address  : Missing ");
	//document.cust.BillingAddress1.focus();
	//return false;
  }
  
   if(document.cust.BillingCountry.value=="") {
   
   TotalMessage=TotalMessage+'Billing Country  : Missing' + '\n';
    //alert("Billing Country  : Missing ");
	//document.cust.BillingCountry.focus();
	//return false;
  }
 
  if(document.cust.BillingCity.value=="") {
  
    TotalMessage=TotalMessage+'Billing City  : Missing' + '\n';
    //alert("Billing City  : Missing ");
	//document.cust.BillingCity.focus();
	//return false;
  }

  if(document.cust.BillingCountry.value=='United States'){
	
		  if(document.cust.BillingState.value=="") {
		  
		   TotalMessage=TotalMessage+'Billing State  : Missing' + '\n';
			//alert("Billing State  : Missing ");
			//document.cust.BillingState.focus();
			//return false;
		  }
	 }
  else{
	 
	 	 if(document.cust.BillingState1.value=="") {
		 
		 //TotalMessage=TotalMessage+'Billing State  : Missing' + '\n';
			
			//alert("Billing State  : Missing ");
			//document.cust.BillingState1.focus();
			//return false;
		  }
	 
	 }

  if(document.cust.BillingZip.value=="") {
  
  TotalMessage=TotalMessage+'Billing Zip  : Missing' + '\n';
  
    //alert("Billing Zip  : Missing ");
	//document.cust.BillingZip.focus();
	//return false;
  }

  if(document.cust.BillingPhone.value=="") {
  
    //TotalMessage=TotalMessage+'Billing Phone  : Missing' + '\n';
	
    //alert("Billing Phone  : Missing ");
	//document.cust.BillingPhone.focus();
	//return false;
  }

      

//////////////////////////  Billing Phone No validation //////////////////////////////////

 if(document.cust.BillingCountry.value=='United States'){
   
		  var str = document.cust.BillingPhone.value;
		  var checkedItemsArray = str.split("-");
	
			
			if(checkedItemsArray.length==3){
	
				var str1=checkedItemsArray[0];
				var str2=checkedItemsArray[1];
				var str3=checkedItemsArray[2];
				
				//alert("HI");
				//alert(str3);
				
				
				if(str1.length!=3) {
				
				//TotalMessage=TotalMessage+'Please enter billing phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter billing phone no in xxx-xxx-xxxx format");
				//document.cust.BillingPhone.focus();
				//return false;
				}
				if(str2.length!=3) {
				
				//TotalMessage=TotalMessage+'Please enter billing phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter billing phone no in xxx-xxx-xxxx format");
				//document.cust.BillingPhone.focus();
				//return false;
				}
				
				if(str3.length!=4) {
				
				//TotalMessage=TotalMessage+'Please enter billing phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter billing phone no in xxx-xxx-xxxx format");
				//document.cust.BillingPhone.focus();
				//return false;
				}
			}
			else{
			
				//TotalMessage=TotalMessage+'Please enter billing phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter billing phone no in xxx-xxx-xxxx format");
				//document.cust.BillingPhone.focus();
				//return false;
			}
			
	}
  else{
  /*
			if (checkInternationalPhone(document.cust.BillingPhone.value)==false){
				alert("Billing phone number must be atleast 10 digits");
				document.cust.BillingPhone.focus();
				return false;
			}*/
	}
//////////////////////////  Billing Phone No validation //////////////////////////////////

  
   if(document.cust.ShippingFirstName.value=="") {
   
    TotalMessage=TotalMessage+'Shipping First Name  : Missing' + '\n';
    
	//alert("Shipping Address  : Missing ");
	//document.cust.ShippingAddress1.focus();
	//return false;
	
  }
  
   if(document.cust.ShippingLastName.value=="") {
   
    TotalMessage=TotalMessage+'Shipping Last Name  : Missing' + '\n';
    
	//alert("Shipping Address  : Missing ");
	//document.cust.ShippingAddress1.focus();
	//return false;
	
  }
  
   if(document.cust.ShippingAddress1.value=="") {
   
    TotalMessage=TotalMessage+'Shipping Address  : Missing' + '\n';
    
	//alert("Shipping Address  : Missing ");
	//document.cust.ShippingAddress1.focus();
	//return false;
	
  }
  
   if(document.cust.ShippingCountry.value=="") {
   
   TotalMessage=TotalMessage+'Shipping Country  : Missing' + '\n';
    
	//alert("Shipping Country  : Missing ");
	//document.cust.ShippingCountry.focus();
	//return false;
	
  }
 
  if(document.cust.ShippingCity.value=="") {
  
  TotalMessage=TotalMessage+'Shipping City  : Missing' + '\n';
  
  
    //alert("Shipping City  : Missing ");
	//document.cust.ShippingCity.focus();
	//return false;
  }

  if(document.cust.ShippingCountry.value=='United States'){

  

	  if(document.cust.ShippingState.value=="") {
	  
	    TotalMessage=TotalMessage+'Shipping State  : Missing' + '\n';
	  
		//alert("Shipping State  : Missing ");
		//document.cust.ShippingState.focus();
		//return false;
	  }
  
  }
  else{
  
  	   if(document.cust.ShippingState1.value=="") {
	   
	    //TotalMessage=TotalMessage+'Shipping State  : Missing' + '\n';
	   
		//alert("Shipping State  : Missing ");
		//document.cust.ShippingState1.focus();
		//return false;
	  }
  
  }
  
  

  if(document.cust.ShippingZip.value=="") {
  
    TotalMessage=TotalMessage+'Shipping Zip  : Missing' + '\n';
	
    //alert("Shipping Zip  : Missing ");
	//document.cust.ShippingZip.focus();
	//return false;
	
  }

  if(document.cust.ShippingPhone.value=="") {
  
    //TotalMessage=TotalMessage+'Shipping Phone  : Missing' + '\n';
  
    //alert("Shipping Phone  : Missing ");
	//document.cust.ShippingPhone.focus();
	//return false;
	
  }

 //////////////////////////  Shipping Phone No validation //////////////////////////////////

 if(document.cust.ShippingCountry.value=='United States'){
   
		  var str = document.cust.ShippingPhone.value;
		  var checkedItemsArray = str.split("-");
	
			
			if(checkedItemsArray.length==3){
	
				var str1=checkedItemsArray[0];
				var str2=checkedItemsArray[1];
				var str3=checkedItemsArray[2];
				
				//alert("HI");
				//alert(str3);
				
				
				if(str1.length!=3) {
				
				 //TotalMessage=TotalMessage+'Please enter shipping phone no in xxx-xxx-xxxx format' + '\n';
				 
				//alert(" Please enter shipping phone no in xxx-xxx-xxxx format");
				//document.cust.ShippingPhone.focus();
				
				//return false;
				}
				if(str2.length!=3) {
				
				//TotalMessage=TotalMessage+'Please enter shipping phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter shipping phone no in xxx-xxx-xxxx format");
				//document.cust.ShippingPhone.focus();
				//return false;
				
				}
				
				if(str3.length!=4) {
				
				//TotalMessage=TotalMessage+'Please enter shipping phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter shipping phone no in xxx-xxx-xxxx format");
				//document.cust.ShippingPhone.focus();
				//return false;
				
				}
			}
			else{
			
				//TotalMessage=TotalMessage+'Please enter shipping phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter shipping phone no in xxx-xxx-xxxx format");
				//document.cust.ShippingPhone.focus();
				//return false;
			}
			
	}
  else{
  
			/*if (checkInternationalPhone(document.cust.ShippingPhone.value)==false){
				alert("Shipping phone number must be atleast 10 digits");
				document.cust.ShippingPhone.focus();
				return false;
			}*/
	}
//////////////////////////  Shipping Phone No validation //////////////////////////////////

 return false;
 
	if(TotalMessage!=""){
		
		 TotalMessage='';
		 return false;
	}	 

  
}

function validBillingInfo() {
document.getElementById('err_FirstName').innerHTML="";
document.getElementById('err_LastName').innerHTML="";
document.getElementById('err_Email').innerHTML="";
document.getElementById('err_BillingAddress1').innerHTML="";
document.getElementById('err_BillingCountry').innerHTML="";
document.getElementById('err_BillingCity').innerHTML="";
document.getElementById('err_BillingState').innerHTML="";
document.getElementById('err_BillingZip').innerHTML="";
document.getElementById('err_ShippingFirstName').innerHTML="";
document.getElementById('err_ShippingLastName').innerHTML="";
document.getElementById('err_ShippingAddress1').innerHTML="";
document.getElementById('err_ShippingCountry').innerHTML="";
document.getElementById('err_ShippingCity').innerHTML="";
document.getElementById('err_ShippingState').innerHTML="";
document.getElementById('err_ShippingZip').innerHTML="";


//alert("HI");
  if(document.cust.FirstName.value=="") {
    //alert("First Name : Missing ");
	///////////////////TotalMessage=TotalMessage+'Please Enter First Name' + '\n';
		
	document.getElementById('err_FirstName').innerHTML='<li style="margin-left:10px">Please Enter First Name</li>';
	document.cust.FirstName.focus();
	TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter First Name</li>'; 
	//document.cust.FirstName.focus();
	//return false;
  }
  else
  {
  if(test(document.cust.FirstName)=="yes")
  {
  document.getElementById('err_FirstName').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
  document.cust.FirstName.focus();
  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters.</li>';
  }
  
  	
  }
  
 if(document.cust.LastName.value=="") {
	//alert("Last Name  : Missing ");
	document.getElementById('err_LastName').innerHTML='<li style="margin-left:10px">Please Enter Last  Name</li>';
	document.cust.LastName.focus();
	TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Last  Name</li>';
	//document.cust.LastName.focus();
	//return false;
  }
  else
  { 
	  if(test(document.cust.LastName)=="yes")
	  {
	  document.getElementById('err_LastName').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
	  document.cust.LastName.focus();
	  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
	  }
 }
  
  //alert(TotalMessage);
  //TotalMessage='';
  //return false;
  
  
   if(document.cust.Email.value=="") {
   document.getElementById('err_Email').innerHTML='<li style="margin-left:10px">Please Enter Last  Email</li>';
   document.cust.Email.focus();
   TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Email</li>';
   
    //alert("E-Mail : Missing ");
	//document.cust.Email.focus();
	//return false;
  }
  
 
  	if(document.cust.Email.value!="")
					{
					   var str=document.cust.Email.value;
					   var er=/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*\.(\w{2}|(com|net|org|edu|in|mil|gov|arpa|biz|aero|name|coop|info|pro|museum))$/;
					   if(!er.test(str))
					   {
					   	    document.getElementById('err_Email').innerHTML='<li style="margin-left:10px">Please Enter Your Valid Email</li>';
						   TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Your Valid Email</li>';
						   //alert ("Please enter your valid email...");
						   //document.cust.Email.focus();
						   //return false;
					   }
					}

  
 if(document.cust.BillingAddress1.value=="") {
 
       document.getElementById('err_BillingAddress1').innerHTML='<li style="margin-left:10px">Please Enter Your Billing Address</li>';
	     document.cust.BillingAddress1.focus();
	 TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Your Billing Address</li>';
    //alert("Billing Address  : Missing ");
	//document.cust.BillingAddress1.focus();
	//return false;
  }
  else
  { 
	  /*if(test(document.cust.BillingAddress1)=="yes")
	  {
	  document.getElementById('err_BillingAddress1').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
	  document.cust.BillingAddress1.focus();
	  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
	  }*/
  }
  
  
   if(document.cust.BillingCountry.value=="") {
   
    document.getElementById('err_BillingCountry').innerHTML='<li style="margin-left:10px">Please Enter Your Billing Country</li>';
	document.cust.BillingCountry.focus();
   TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Your Billing Country</li>';
    //alert("Billing Country  : Missing ");
	//document.cust.BillingCountry.focus();
	//return false;
  }
  else
  { 
	  if(test(document.cust.BillingCountry)=="yes")
	  {
	  document.getElementById('err_BillingCountry').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
	  document.cust.BillingCountry.focus();
	  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
	  }
  }
 
  if(document.cust.BillingCity.value=="") {
  
    document.getElementById('err_BillingCity').innerHTML='<li style="margin-left:10px">Please Enter Your Billing City</li>';
	document.cust.BillingCity.focus();
	TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Your Billing City</li>';
    //alert("Billing City  : Missing ");
	//document.cust.BillingCity.focus();
	//return false;
  }
 else
  { 
	  if(test(document.cust.BillingCity)=="yes")
	  {
	  document.getElementById('err_BillingCity').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
	  document.cust.BillingCountry.focus();
	  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
	  }
  }


  if(document.cust.BillingCountry.value=='United States'){
	
		  if(document.cust.BillingState.value=="") {
		  
		  document.getElementById('err_BillingState').innerHTML='<li style="margin-left:10px">Please Enter Your Billing State</li>';
		   TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Your Billing State</li>';
			//alert("Billing State  : Missing ");
			//document.cust.BillingState.focus();
			//return false;
		  }	 }
  else{
	 
	 	 if(document.cust.BillingState1.value=="") {
		 
		  document.getElementById('err_BillingState').innerHTML='<li style="margin-left:10px">Please Enter Your Billing State</li>';
		 
		 //TotalMessage=TotalMessage+'Billing State  : Missing' + '\n';
			
			//alert("Billing State  : Missing ");
			//document.cust.BillingState1.focus();
			//return false;
		  }
		  
	 
	 }

  if(document.cust.BillingZip.value=="") {
  
    document.getElementById('err_BillingZip').innerHTML='<li style="margin-left:10px">Please Enter Your Billing Zip</li>';
	document.cust.BillingZip.focus();
  TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Your Billing Zip</li>';
  
    //alert("Billing Zip  : Missing ");
	//document.cust.BillingZip.focus();
	//return false;
  }
  else
  { 
			  if(test(document.cust.BillingZip)=="yes")
			  {
			  document.getElementById('err_BillingZip').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
			  document.cust.BillingZip.focus();
			  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
			  }
  		 }

  if(document.cust.BillingPhone.value=="") {
  
    //TotalMessage=TotalMessage+'Billing Phone  : Missing' + '\n';
	
    //alert("Billing Phone  : Missing ");
	//document.cust.BillingPhone.focus();
	//return false;
  }
  else
  { 
  }

      

//////////////////////////  Billing Phone No validation //////////////////////////////////

 if(document.cust.BillingCountry.value=='United States'){
   
		  var str = document.cust.BillingPhone.value;
		  var checkedItemsArray = str.split("-");
	
			
			if(checkedItemsArray.length==3){
	
				var str1=checkedItemsArray[0];
				var str2=checkedItemsArray[1];
				var str3=checkedItemsArray[2];
				
				//alert("HI");
				//alert(str3);
				
				
				if(str1.length!=3) {
				
				//TotalMessage=TotalMessage+'Please enter billing phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter billing phone no in xxx-xxx-xxxx format");
				//document.cust.BillingPhone.focus();
				//return false;
				}
				if(str2.length!=3) {
				
				//TotalMessage=TotalMessage+'Please enter billing phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter billing phone no in xxx-xxx-xxxx format");
				//document.cust.BillingPhone.focus();
				//return false;
				}
				
				if(str3.length!=4) {
				
				//TotalMessage=TotalMessage+'Please enter billing phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter billing phone no in xxx-xxx-xxxx format");
				//document.cust.BillingPhone.focus();
				//return false;
				}
			}
			else{
			
				//TotalMessage=TotalMessage+'Please enter billing phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter billing phone no in xxx-xxx-xxxx format");
				//document.cust.BillingPhone.focus();
				//return false;
			}
			
	}
  else{
  /*
			if (checkInternationalPhone(document.cust.BillingPhone.value)==false){
				alert("Billing phone number must be atleast 10 digits");
				document.cust.BillingPhone.focus();
				return false;
			}*/
	}
//////////////////////////  Billing Phone No validation //////////////////////////////////

  
   if(document.cust.ShippingFirstName.value=="") {
   
    document.getElementById('err_ShippingFirstName').innerHTML='<li style="margin-left:10px">Please Enter Shipping First Name</li>';
		document.cust.ShippingFirstName.focus();
    TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Shipping First Name</li>';
    
	//alert("Shipping Address  : Missing ");
	//document.cust.ShippingAddress1.focus();
	//return false;
	
  }
 else
  { 
			  if(test(document.cust.ShippingFirstName)=="yes")
			  {
			  document.getElementById('err_ShippingFirstName').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
			  document.cust.ShippingFirstName.focus();
			  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
			  }
  }
  
   if(document.cust.ShippingLastName.value=="") {
   
     document.getElementById('err_ShippingLastName').innerHTML='<li style="margin-left:10px">Please Enter Shipping Last Name</li>';
	 	document.cust.ShippingLastName.focus();
	
	TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Shipping Last Name</li>';
    
	//alert("Shipping Address  : Missing ");
	//document.cust.ShippingAddress1.focus();
	//return false;
	
  }
   else
  { 
			  if(test(document.cust.ShippingLastName)=="yes")
			  {
			  document.getElementById('err_ShippingLastName').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
			  document.cust.ShippingLastName.focus();
			  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
			  }
  }
  
   if(document.cust.ShippingAddress1.value=="") {
   
    document.getElementById('err_ShippingAddress1').innerHTML='<li style="margin-left:10px">Please Enter Shipping Address</li>';
	document.cust.ShippingAddress1.focus();
    TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Shipping Address</li>';
    
	//alert("Shipping Address  : Missing ");
	//document.cust.ShippingAddress1.focus();
	//return false;
	
  }
   else
  { 
			 /* if(test(document.cust.ShippingAddress1)=="yes")
			  {
			  document.getElementById('err_ShippingAddress1').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
			  document.cust.ShippingAddress1.focus();
			  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
			  }*/
  }
  
   if(document.cust.ShippingCountry.value=="") {
   
    document.getElementById('err_ShippingCountry').innerHTML='<li style="margin-left:10px">Please Enter Shipping Country</li>';

   TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Shipping Country </li>';
    
	//alert("Shipping Country  : Missing ");
	//document.cust.ShippingCountry.focus();
	//return false;
	
  }
  
 
  if(document.cust.ShippingCity.value=="") {
  
  document.getElementById('err_ShippingCity').innerHTML='<li style="margin-left:10px">Please Enter Shipping City</li>';
  document.cust.ShippingCity.focus();
  TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Shipping City </li>';
  
  
    //alert("Shipping City  : Missing ");
	//document.cust.ShippingCity.focus();
	//return false;
  }
   else
  { 
			  if(test(document.cust.ShippingCity)=="yes")
			  {
			  document.getElementById('err_ShippingCity').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
			  document.cust.ShippingCity.focus();
			  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
			  }
  }

  if(document.cust.ShippingCountry.value=='United States'){

  

	  if(document.cust.ShippingState.value=="") {
	   document.getElementById('err_ShippingState').innerHTML='<li style="margin-left:10px">Please Enter Shipping State</li>';
	   
	    TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Shipping State </li>';
	  
		//alert("Shipping State  : Missing ");
		//document.cust.ShippingState.focus();
		//return false;
	  }
  
  }
  else{
  
  	   if(document.cust.ShippingState1.value=="") {
	   
	    document.getElementById('err_ShippingState').innerHTML='<li style="margin-left:10px">Please Enter Shipping State</li>';
	    //TotalMessage=TotalMessage+'Shipping State  : Missing' + '\n';
	   
		//alert("Shipping State  : Missing ");
		//document.cust.ShippingState1.focus();
		//return false;
	  }
  
  }
  
  

  if(document.cust.ShippingZip.value=="") {
  
     document.getElementById('err_ShippingZip').innerHTML='<li style="margin-left:10px">Please Enter Shipping Zip</li>';
	  document.cust.ShippingZip.focus();
    TotalMessage=TotalMessage+'<li style="margin-left:10px">Please Enter Shipping Zip </li>';
	
    //alert("Shipping Zip  : Missing ");
	//document.cust.ShippingZip.focus();
	//return false;
	
  }
  else
  { 
			  if(test(document.cust.ShippingZip)=="yes")
			  {
			  document.getElementById('err_ShippingZip').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
			  document.cust.ShippingZip.focus();
			  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
			  }
  }

  if(document.cust.ShippingPhone.value=="") {
  
    //TotalMessage=TotalMessage+'Shipping Phone  : Missing' + '\n';
  
    //alert("Shipping Phone  : Missing ");
	//document.cust.ShippingPhone.focus();
	//return false;
	
  }
  else
  { 
			  if(test(document.cust.ShippingPhone)=="yes")
			  {
			  document.getElementById('err_ShippingPhone').innerHTML='<li style="margin-left:10px">These are not allowed special characters</li>';
			  document.cust.ShippingPhone.focus();
			  TotalMessage=TotalMessage+'<li style="margin-left:10px">These are not allowed special characters</li>';
			  }
  }

 //////////////////////////  Shipping Phone No validation //////////////////////////////////

 if(document.cust.ShippingCountry.value=='United States'){
   
		  var str = document.cust.ShippingPhone.value;
		  var checkedItemsArray = str.split("-");
	
			
			if(checkedItemsArray.length==3){
	
				var str1=checkedItemsArray[0];
				var str2=checkedItemsArray[1];
				var str3=checkedItemsArray[2];
				
				//alert("HI");
				//alert(str3);
				
				
				if(str1.length!=3) {
				
				 //TotalMessage=TotalMessage+'Please enter shipping phone no in xxx-xxx-xxxx format' + '\n';
				 
				//alert(" Please enter shipping phone no in xxx-xxx-xxxx format");
				//document.cust.ShippingPhone.focus();
				
				//return false;
				}
				if(str2.length!=3) {
				
				//TotalMessage=TotalMessage+'Please enter shipping phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter shipping phone no in xxx-xxx-xxxx format");
				//document.cust.ShippingPhone.focus();
				//return false;
				
				}
				
				if(str3.length!=4) {
				
				//TotalMessage=TotalMessage+'Please enter shipping phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter shipping phone no in xxx-xxx-xxxx format");
				//document.cust.ShippingPhone.focus();
				//return false;
				
				}
			}
			else{
			
				//TotalMessage=TotalMessage+'Please enter shipping phone no in xxx-xxx-xxxx format' + '\n';
				
				//alert(" Please enter shipping phone no in xxx-xxx-xxxx format");
				//document.cust.ShippingPhone.focus();
				//return false;
			}
			
	}
  else{
  
			/*if (checkInternationalPhone(document.cust.ShippingPhone.value)==false){
				alert("Shipping phone number must be atleast 10 digits");
				document.cust.ShippingPhone.focus();
				return false;
			}*/
	}
//////////////////////////  Shipping Phone No validation //////////////////////////////////

	if(TotalMessage!=""){
	
		//document.getElementById('errorMsgdisplay').innerHTML=TotalMessage;
		
		 //alert(TotalMessage);
		 TotalMessage='';
		 return false;
	}	 
	
	

}



/**
 * DHTML phone number validation script. Courtesy of SmartWebby.com (http://www.smartwebby.com/dhtml/)
 */

// Declaring required variables
var digits = "0123456789";
// non-digit characters which are allowed in phone numbers
var phoneNumberDelimiters = "()- .";
// characters which are allowed in international phone numbers
// (a leading + is OK)
var validWorldPhoneChars = phoneNumberDelimiters + "+";
// Minimum no of digits in an international phone no.
var minDigitsInIPhoneNumber = 10;

function isInteger(s)
{   var i;
    for (i = 0; i < s.length; i++)
    {   
        // Check that current character is number.
        var c = s.charAt(i);
        if (((c < "0") || (c > "9"))) return false;
    }
    // All characters are numbers.
    return true;
}
function trim(s)
{   var i;
    var returnString = "";
    // Search through string's characters one by one.
    // If character is not a whitespace, append to returnString.
    for (i = 0; i < s.length; i++)
    {   
        // Check that current character isn't whitespace.
        var c = s.charAt(i);
        if (c != " ") returnString += c;
    }
    return returnString;
}
function stripCharsInBag(s, bag)
{   var i;
    var returnString = "";
    // Search through string's characters one by one.
    // If character is not in bag, append to returnString.
    for (i = 0; i < s.length; i++)
    {   
        // Check that current character isn't whitespace.
        var c = s.charAt(i);
        if (bag.indexOf(c) == -1) returnString += c;
    }
    return returnString;
}

function checkInternationalPhone(strPhone){
var bracket=3
strPhone=trim(strPhone)
if(strPhone.indexOf("+")>1) return false
if(strPhone.indexOf("-")!=-1)bracket=bracket+1
if(strPhone.indexOf("(")!=-1 && strPhone.indexOf("(")>bracket)return false
var brchr=strPhone.indexOf("(")
if(strPhone.indexOf("(")!=-1 && strPhone.charAt(brchr+2)!=")")return false
if(strPhone.indexOf("(")==-1 && strPhone.indexOf(")")!=-1)return false
s=stripCharsInBag(strPhone,validWorldPhoneChars);
return (isInteger(s) && s.length >= minDigitsInIPhoneNumber);
}


<!--
/* 
SlideShow. Written by PerlScriptsJavaScripts.com
Copyright http://www.perlscriptsjavascripts.com 
Free and commercial Perl and JavaScripts     
*/

// transition effect. number between 0 and 23, 23 is random effect
effect = 23; 

// transition duration. number of seconds effect lasts
duration = 1.5; 

// seconds to diaply each image?
display = 4;

// width of stage (first image)
oW = 429;

// height of stage
oH = 600;

// zoom width by (add or subtracts this many pixels from image width)
zW = 40;

// zoom height by 
zH = 30;

// path to image/name of image in slide show. this will also preload all images
// each element in the array must be in sequential order starting with zero (0)


// end required modifications

/*for(a = 0; a < SLIDES.length; a++){
	S[a] = new Image(); S[a].src  = SLIDES[a][0];
}*/
// -->


<!-- Original:  Paul Deron (trombonepaul@yahoo.com) -->
<!-- Web Site:  http://paul1.web.com -->

<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->

<!-- Begin
function fullScreen(theURL) {
window.open(theURL, '', 'fullscreen=yes, scrollbars=auto');
}
//  End -->










<!--[if IE]>





/* This script and many more are available free online at
The JavaScript Source!! http://javascript.internet.com
Created by: Mr J | http://www.huntingground.net/ */

scrollStep=1

timerLeft=""
timerRight=""

function toLeft(id){
  document.getElementById(id).scrollLeft=0
}

function scrollDivLeft(id){
  clearTimeout(timerRight) 
  document.getElementById(id).scrollLeft+=scrollStep
  timerRight=setTimeout("scrollDivLeft('"+id+"')",10)
}

function scrollDivRight(id){
  clearTimeout(timerLeft)
  document.getElementById(id).scrollLeft-=scrollStep
  timerLeft=setTimeout("scrollDivRight('"+id+"')",10)
}

function toRight(id){
  document.getElementById(id).scrollLeft=document.getElementById(id).scrollWidth
}

function stopMe(){
  clearTimeout(timerRight) 
  clearTimeout(timerLeft)
}


