function copydetails()
{
	
	document.shopform.tickethonorific.selectedIndex = document.shopform.honorific.selectedIndex ;
	
	document.shopform.ticketFirstname.value = document.shopform.Firstname.value ;
	document.shopform.ticketLastname.value = document.shopform.Lastname.value ;
	document.shopform.tickethouseno.value = document.shopform.Houseno.value ;
	document.shopform.ticketmembership.value = document.shopform.membership.value ;
	
	
	document.shopform.ticketAddress.value = document.shopform.Address.value ;
	document.shopform.ticketAddress2.value = document.shopform.Address2.value ;
	document.shopform.ticketTown.value = document.shopform.Town.value ;
	document.shopform.ticketcounty.value = document.shopform.county.value ;
	document.shopform.ticketPostcode.value = document.shopform.Postcode.value ;
	
	document.shopform.DayNumber2.value = document.shopform.DayNumber.value ;
	document.shopform.NightNumber2.value = document.shopform.NightNumber.value ;
	
	document.shopform.email2.value = document.shopform.email.value ;
	document.shopform.dob2.value = document.shopform.dob.value ;
	
	
}


function valleyexpressadd()
{

   var expresstotal = 0 ;
   // var price = 'document.shopform.valleyexpressprice.value' ;
   
   var pickup = document.shopform.pickup.options[shopform.pickup.selectedIndex].value;
   var firstletter=pickup.charAt(0);
 
   
   if (firstletter == '*')
   	{
   		document.shopform.valleyexpressprice.value = '150' ;
   		var price = 'document.shopform.valleyexpressprice.value' ;
   	}
   	else
   	{
   		document.shopform.valleyexpressprice.value = '95' ;
   		var price = 'document.shopform.valleyexpressprice.value' ;
   	}
   	
   var item = 'document.shopform.valleyexpress.checked' ;

   

   if (eval(item))
   {
   if (pickup =='') 
   {
   	alert('Please Select a pickup point') ;
   }
   expresstotal = parseInt(eval(price)) ;
   
   document.shopform.valleyexpressdisplay.value = expresstotal ;
   
   }
   else
   {
   document.shopform.valleyexpressdisplay.value = '' ;
   }
   document.shopform.expresstotal.value = expresstotal ;
   document.shopform.gtotal.value = parseInt(shopform.cartotal.value) + parseInt(shopform.bartotal.value) + parseInt(shopform.expresstotal.value) + parseInt(shopform.ticketprice.value);

   
   if (document.shopform.cartotal.value > 0 && document.shopform.valleyexpressdisplay.value == document.shopform.valleyexpressprice.value ) 
   {
   alert('You should not select Valley Express and Car Park Tickets') ;
   }


   //if (shopform.fiveyear.checked)
   //{
   //   shopform.gtotal.value = parseInt(shopform.gtotal.value) - parseInt(shopform.ticketprice.value) ;
   //}
   

}

function carparkadd()
{


   var cartotal = 0 ;
   var carhits = 0 ;
   for (i = 1; i <= 3; i++)
   {
      var price = 'document.shopform.carpark'+ i +'price.value' ;
      var item = 'document.shopform.carpark'+ i +'.checked' ;
      
      if (eval(item))
      {
      cartotal = parseInt(cartotal) +  parseInt(eval(price)) ;
      document.shopform.elements['carparkdisplay'+i].value = eval(price) ;
      var carhits = carhits  + 1 ;
      }
      else
      {
      document.shopform.elements['carparkdisplay'+i].value = '' ;
      }
   }
   
   
   if (carhits > 0 && document.shopform.valleyexpressdisplay.value == '85') 
   {
   	alert('You should not select Valley Express and Car Park Tickets') ;
   }
   
   if (carhits > 1)
   {
   alert('You should select only one car park') ;
   }
   
   // alert(cartotal) ;
   document.shopform.cartotal.value = cartotal ;
   document.shopform.gtotal.value = parseInt(document.shopform.cartotal.value) + parseInt(document.shopform.bartotal.value) + parseInt(document.shopform.expresstotal.value) + parseInt(document.shopform.ticketprice.value);
   
   
   //if (document.shopform.fiveyear.checked)
   //{
   //  document.shopform.gtotal.value = parseInt(document.shopform.gtotal.value) - parseInt(document.shopform.ticketprice.value) ;
   //}
   
   
}




function baradd()
{

   var bartotal = 0 ;
   var barhits = 0 ;
   for (i = 1; i <= 3; i++)
   {
      var price = 'shopform.bar'+ i +'price.value' ;
      var item = 'shopform.bar'+ i +'.checked' ;

      if (eval(item))
      {
      bartotal = parseInt(bartotal) +  parseInt(eval(price)) ;
      document.shopform.elements['bardisplay'+i].value = eval(price) ;
      var barhits = barhits  + 1 ;
      }
      else
      {
      document.shopform.elements['bardisplay'+i].value = '' ;
      }
      
   }
   if (barhits > 1)
   {
      alert('You should select only one bar membership') ;
   }
   // alert(bartotal) ;
   document.shopform.bartotal.value = bartotal ;
   document.shopform.gtotal.value = parseInt(shopform.cartotal.value) + parseInt(shopform.bartotal.value) + parseInt(shopform.expresstotal.value) + parseInt(shopform.ticketprice.value);

   //if (document.shopform.fiveyear.checked)
   //   {
   //   document.shopform.gtotal.value = parseInt(document.shopform.gtotal.value) - parseInt(document.shopform.ticketprice.value) ;
   //   }
   
   
      
}

function fixtotal()

{
   alert('You cannot change this value') ;
   document.shopform.gtotal.value = parseInt(document.shopform.cartotal.value) + parseInt(document.shopform.bartotal.value) + parseInt(document.shopform.expresstotal.value) + parseInt(document.shopform.ticketprice.value);

   
      document.shopform.gtotal.value = parseInt(document.shopform.gtotal.value) + parseInt(document.shopform.ticketprice.value) ;
      document.shopform.gtotal.value = parseInt(document.shopform.gtotal.value) - parseInt(document.shopform.ticketprice.value) ;
   
}


function fiveyearsub()
{
  
   if (document.shopform.fiveyear.checked)
      {
      document.shopform.gtotal.value = parseInt(document.shopform.gtotal.value) - parseInt(document.shopform.ticketprice.value) ;
      }
   else
      {
      document.shopform.gtotal.value = parseInt(document.shopform.gtotal.value) + parseInt(document.shopform.ticketprice.value) ;
      }
}


/* function for valley express season tickets */


function vxpressadd()
{

   var expresstotal = 0 ;
   // var price = 'document.shopform.valleyexpressprice.value' ;
   
   var pickup = document.shopform.pickup.options[shopform.pickup.selectedIndex].value;
   var firstletter=pickup.charAt(0);
 
   
   if (firstletter == '*')
   	{
   		document.shopform.itemp1.value = '150.00' ;
   		var price = 'document.shopform.itemp1.value' ;
   	}
   	else
   	{
   		document.shopform.itemp1.value = '95.00' ;
   		var price = 'document.shopform.itemp1.value' ;
   	}
   	
   





	   if (pickup =='') 
	   {
	   	alert('Please Select a pickup point') ;
	   }
	   else
	   {
	   qty = document.shopform.qty1.value ;
	   expresstotal = parseInt(eval(price)) ;
   	   document.shopform.ltotal1.value = expresstotal * qty ;
	   document.shopform.gtotal.value = expresstotal * qty;   

	   }


   
   

}



