function suggestionkapat(nesne){
var element='';
	switch(nesne){
		case 1:
		element='from';
		break;
		case 2:
		element='to';
		break;
		case 3:
		element='dfrom';
		break;
		case 4:
		element='dto';
		break;
		}
	$('#'+element+'suggestions').hide();
	clearTimeout ('suggestionacikkontrol');
	}
	function lookup(inputString,nesne) {
		if(inputString.length == 0) {
			// Hide the suggestion box.
			$('#'+nesne+'suggestions').hide();
		} else {
			$.post("include/locationsuggestionbox.php?nesne="+nesne, {queryString: ""+inputString+""}, function(data){
				if(data.length >0) {
					$('#'+nesne+'suggestions').show();
					$('#'+nesne+'autoSuggestionsList').html(data);
				}
			});
		}
	} // lookup
	
	function fill(thisValue,nesne,bolgeid) {
		$('#'+nesne).val(thisValue);
		$('#'+nesne+'bolgeisim').val(document.getElementById(nesne).value);
		$('#'+nesne+'bolgeid').val(bolgeid);
		document.getElementById(nesne+'hata').innerHTML='<img src="images/onay.png" border="0" alt="OK"/>';
		setTimeout("$('#"+nesne+"suggestions').hide();", 200);
			if(nesne=='from' || nesne=='to'){
			fiyathesapla(true,1);
			}
		else{
			fiyathesapla(true,2);
			}
		formayarla();
		tavsiyeedilenpickupzamani(2);
	}
function acentatursepetibilgilerigonder(mod){
	durum=true;
	var nesne='ad||soyad';
	var nesneler=nesne.split('||');
	for(var i=0;i<nesneler.length;i++){
		var icerik=trim(document.getElementById(nesneler[i]).value);
	if(icerik.length==0){
	alert('Lütfen boş bırakmayınız: '+nesneler[i]);
	durum=false;
		}
	}
	if(durum){
		if(mod==1){
	ajaxverikaydet('include/tursiparistamamla.php?tid='+document.getElementById('tur').value+'&k='+document.getElementById('kisi').value+'&tarih='+document.getElementById('tarih').value+'&t='+document.getElementById('toplam').value+'&ad='+document.getElementById('ad').value+'&soyad='+document.getElementById('soyad').value+'&eknot='+document.getElementById('eknot').value+'&dl='+document.getElementById('dl').value+'&h='+document.getElementById('oteller').options[document.getElementById('oteller').selectedIndex].value+'&o='+document.getElementById('odemeturu').options[document.getElementById('odemeturu').selectedIndex].value,true,'siparis'+document.getElementById('turid').value);
		}
		else if(mod==2){
		ajaxverikaydet('include/tursiparistamamla.php?tid='+document.getElementById('tur').value+'&k='+document.getElementById('kisi').value+'&tarih='+document.getElementById('tarih').value+'&t='+document.getElementById('toplam').value+'&ad='+document.getElementById('ad').value+'&soyad='+document.getElementById('soyad').value+'&eknot='+document.getElementById('eknot').value+'&dl='+document.getElementById('dl').value+'&h='+document.getElementById('oteller').options[document.getElementById('oteller').selectedIndex].value+'&mt='+document.getElementById('mt').options[document.getElementById('mt').selectedIndex].value+'&o='+document.getElementById('odemeturu').options[document.getElementById('odemeturu').selectedIndex].value+'&saat='+document.getElementById('tsaat').options[document.getElementById('tsaat').selectedIndex].value+'&dak='+document.getElementById('tdak').options[document.getElementById('tdak').selectedIndex].value,true,'siparis'+document.getElementById('turid').value);
		}
	}
}
function tursepetibilgilerigonder(){
	durum=true;
	var nesne='ad||soyad';
	var nesneler=nesne.split('||');
	for(var i=0;i<nesneler.length;i++){
		var icerik=trim(document.getElementById(nesneler[i]).value);
	if(icerik.length==0){
	alert('Lütfen boş bırakmayınız: '+nesneler[i]);
	durum=false;
		}
	}
	if(durum){
	ajaxverikaydet('include/tursiparistamamla.php?tid='+document.getElementById('tur').value+'&k='+document.getElementById('kisi').value+'&tarih='+document.getElementById('tarih').value+'&t='+document.getElementById('toplam').value+'&ad='+document.getElementById('ad').value+'&soyad='+document.getElementById('soyad').value+'&eknot='+document.getElementById('eknot').value+'&dl='+document.getElementById('dl').value+'&o='+document.getElementById('odemeturu').options[document.getElementById('odemeturu').selectedIndex].value,true,'siparis'+document.getElementById('turid').value);
	}
}
function turfiyatsil(silinecektur){
	if(silinecektur.length>0){
	var alinanurunid=document.getElementById('alinanurunid').value;
	var yenialinanurunid='';
		var alinanurunicon1=alinanurunid.split('||');
			for(r=0;r<alinanurunicon1.length;r++){
				if(alinanurunicon1[r]!=silinecektur){
					if(yenialinanurunid.length>0){
						yenialinanurunid=yenialinanurunid+'||'+alinanurunicon1[r];
						}
					else{

						yenialinanurunid=alinanurunicon1[r];
						}
					}
			}
	var alinanurunicon2='';
	var toplamfiyat=0;
	if(yenialinanurunid.length>0){
	alinanurunicon1=yenialinanurunid.split('||');
	var alinanurunicon2='';
	for(r=0;r<alinanurunicon1.length;r++){
		var icon=alinanurunicon1[r].split('&');
		var tarihparcala=icon[3].split('-');
	alinanurunicon2=alinanurunicon2+'<tr><td align="center"><img src="uploadedfiles/'+document.getElementById('icon'+icon[0]).value+'" border="0"></td><td width="10"></td><td align="left"><a class="normalsiyah">'+tarihparcala[0]+'-'+ingtarih(tarihparcala[1])+'-'+tarihparcala[2]+' Dated</a></td><td width="10"></td><td align="left"><a class="normalsiyah">'+icon[2]+' Person(s)</a></td><td width="10"></td><td align="left"><a class="normalsiyah">'+icon[1]+' Euro</a></td><td width="10"></td><td width="15" align="left"><img src="images/sil.png" border="0" style="cursor:pointer;" onclick="javascript:turfiyatsil('+"'"+alinanurunicon1[r]+"'"+')"></td></tr>';
	toplamfiyat=(toplamfiyat*1)+(icon[1]*1);
	}
	}
	else{
		alinanurunicon2='<a class="normalsiyah">Please add at least one tour package.</a>';
		}
	document.getElementById('alinanurunid').value=yenialinanurunid;
	document.getElementById('alinanurunler').innerHTML='<table cellpadding="0" cellspacing="0" border="0">'+alinanurunicon2+'</table>';
	document.getElementById('totalprice').innerHTML=toplamfiyat;
		}
	}
	
function hataligunbul(fiyat,kisisayisi,sayi,sayfa){
var xmlHttp;
try
  {
  // Firefox, Opera 8.0+, Safari
  xmlHttp=new XMLHttpRequest();
  }
catch (e)
  {
  // Internet Explorer
  try
    {
    xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
    }
  catch (e)
    {
    try
      {
      xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
      }
    catch (e)
      {
      alert("Kullandığınız web tarayıcısı AJAX Desteklememektedir.");
      return false;
      }
    }
  }
xmlHttp.onreadystatechange=function()
    {
    if(xmlHttp.readyState==4)
      {
	  var gelenicerik=xmlHttp.responseText;
	  if(gelenicerik=='true'){
		turfiyathesapla(fiyat,kisisayisi,sayi,true);
	  }
	  }
    }
	var gonderileceksayfa=sayfa;
	//alert(gonderileceksayfa);
	//xmlHttp.onreadystatechange=stateChanged;
	xmlHttp.open("GET",gonderileceksayfa,true);
	xmlHttp.send(null);	
	}
function turfiyathesapla(fiyat,kisisayisi,sayi,durum){
	if(durum){
	var alinanurunid=document.getElementById('alinanurunid').value;
	var turtarihi=document.getElementById('tarihgun'+sayi).value+'-'+document.getElementById('tarihay'+sayi).value+'-'+document.getElementById('tarihyil'+sayi).value;
	var alinanurunicon1=alinanurunid.split('||');
	var oncedenvarmi=false;
	var eklenecektoplamfiyat=(document.getElementById(fiyat).value*document.getElementById(kisisayisi).options[document.getElementById(kisisayisi).selectedIndex].value);
	var ek=sayi+'&'+((document.getElementById('total'+sayi).value*1)+eklenecektoplamfiyat)+'&'+document.getElementById(kisisayisi).options[document.getElementById(kisisayisi).selectedIndex].value+'&'+turtarihi;
	if(alinanurunid.length>0){
		for(r=0;r<alinanurunicon1.length;r++){
		var icon=alinanurunicon1[r].split('&');
		if(icon[0]==sayi && icon[3]==turtarihi){
			oncedenvarmi=true;
			var yenieklenecektoplamfiyat=(icon[1]*1)+eklenecektoplamfiyat;
			var yenieklenecektoplamkisi=(icon[2]*1)+(document.getElementById(kisisayisi).options[document.getElementById(kisisayisi).selectedIndex].value*1);
			alinanurunid=alinanurunid.replace(icon[0]+'&'+icon[1]+'&'+icon[2]+'&'+icon[3],icon[0]+'&'+yenieklenecektoplamfiyat+'&'+yenieklenecektoplamkisi+'&'+icon[3]);
			ek='';
			}
		}
		if(ek.length>0){
		alinanurunid=alinanurunid+'||'+ek;
		}
	}
	else{
	alinanurunid=ek;
	}
	var toplamfiyat=0;
	if(alinanurunid.length>0){
	alinanurunicon1=alinanurunid.split('||');
	var alinanurunicon2='';
	for(r=0;r<alinanurunicon1.length;r++){
		var icon=alinanurunicon1[r].split('&');
		var tarihparcala=icon[3].split('-');
	alinanurunicon2=alinanurunicon2+'<tr><td align="center"><img src="uploadedfiles/'+document.getElementById('icon'+icon[0]).value+'" border="0"></td><td width="10"></td><td align="left"><a class="normalsiyah">'+tarihparcala[0]+'-'+ingtarih(tarihparcala[1])+'-'+tarihparcala[2]+' Dated</a></td><td width="10"></td><td align="left"><a class="normalsiyah">'+icon[2]+' Person(s)</a></td><td width="10"></td><td align="left"><a class="normalsiyah">'+icon[1]+' Euro</a></td><td width="10"></td><td width="15" align="left"><img src="images/sil.png" border="0" style="cursor:pointer;" onclick="javascript:turfiyatsil('+"'"+alinanurunicon1[r]+"'"+')"></td></tr>';
	toplamfiyat=(toplamfiyat*1)+(icon[1]*1);
	}
	}
	else{
		alinanurunicon2='<a class="normalsiyah">Please add at least one tour package.</a>';
	}
	document.getElementById('alinanurunid').value=alinanurunid;
	document.getElementById('alinanurunler').innerHTML='<table cellpadding="0" cellspacing="0" border="0">'+alinanurunicon2+'</table>';
	document.getElementById('totalprice').innerHTML=toplamfiyat;
	}
}
function kayitokuislem(kayitid,mod,bk,bkm){
	var xmlHttp;
try
  {
  // Firefox, Opera 8.0+, Safari
  xmlHttp=new XMLHttpRequest();
  }
catch (e)
  {
  // Internet Explorer
  try
    {
    xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
    }
  catch (e)
    {
    try
      {
      xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
      }
    catch (e)
      {
      alert("Kullandığınız web tarayıcısı AJAX Desteklememektedir.");
      return false;
      }
    }
  }
xmlHttp.onreadystatechange=function()
    {
    if(xmlHttp.readyState==4)
      {
		  if(bkm=='3'){
	  var anaicerik=xmlHttp.responseText;
	  var gelenicerik=anaicerik.split("#|#|#");
	  var bolumlenmisicerikbireysel=gelenicerik[0].split("||");
	  document.getElementById("bonayli").innerHTML=bolumlenmisicerikbireysel[1];
	  document.getElementById("bred").innerHTML=bolumlenmisicerikbireysel[2];
	  document.getElementById("bbekleyen").innerHTML=bolumlenmisicerikbireysel[3];
	  document.getElementById("btumu").innerHTML=bolumlenmisicerikbireysel[0];
  	  var bolumlenmisicerikkurumsal=gelenicerik[1].split("||");
	  document.getElementById("konayli").innerHTML=bolumlenmisicerikkurumsal[1];
	  document.getElementById("kred").innerHTML=bolumlenmisicerikkurumsal[2];
	  document.getElementById("kbekleyen").innerHTML=bolumlenmisicerikkurumsal[3];
	  document.getElementById("ktumu").innerHTML=bolumlenmisicerikkurumsal[0];
	  if(bk=='1'){
	  	  if(mod=='-1'){
		document.getElementById("bireyselyenikayitsayisi").innerHTML=bolumlenmisicerikbireysel[0];
		  }
	  else if(mod=='1'){
		 document.getElementById("bireyselyenikayitsayisi").innerHTML=bolumlenmisicerikbireysel[1]; 
		  }
	  else if(mod=='2'){
		 document.getElementById("bireyselyenikayitsayisi").innerHTML=bolumlenmisicerikbireysel[2]; 
		  }
	  else if(mod=='3'){
		 document.getElementById("bireyselyenikayitsayisi").innerHTML=bolumlenmisicerikbireysel[3]; 
		  }
	  }
	  else if(bk=='2'){
	  if(mod=='-1'){
		document.getElementById("kurumsalyenikayitsayisi").innerHTML=bolumlenmisicerikkurumsal[0];
		  }
	  else if(mod=='1'){
		 document.getElementById("kurumsalyenikayitsayisi").innerHTML=bolumlenmisicerikkurumsal[1]; 
		  }
	  else if(mod=='2'){
		 document.getElementById("kurumsalyenikayitsayisi").innerHTML=bolumlenmisicerikkurumsal[2]; 
		  }
	  else if(mod=='3'){
		 document.getElementById("kurumsalyenikayitsayisi").innerHTML=bolumlenmisicerikkurumsal[3]; 
		  }
	  }
		  }
		  else{
	  var gelenicerik=xmlHttp.responseText;
	  var bolumlenmisicerik=gelenicerik.split("||");
	  document.getElementById("onayli").innerHTML=bolumlenmisicerik[1];
	  document.getElementById("red").innerHTML=bolumlenmisicerik[2];
	  document.getElementById("bekleyen").innerHTML=bolumlenmisicerik[3];
	  document.getElementById("tumu").innerHTML=bolumlenmisicerik[0];
	  if(mod=='-1'){
		 document.getElementById("yenikayitsayisi").innerHTML=bolumlenmisicerik[0];
		  }
	  else if(mod=='1'){
		 document.getElementById("yenikayitsayisi").innerHTML=bolumlenmisicerik[1]; 
		  }
	  else if(mod=='2'){
		 document.getElementById("yenikayitsayisi").innerHTML=bolumlenmisicerik[2]; 
		  }
	  else if(mod=='3'){
		 document.getElementById("yenikayitsayisi").innerHTML=bolumlenmisicerik[3]; 
		  }
			  }
      }
    }
	var sayfa="include/transferkayitoku.php?kid="+kayitid+"&bk="+bk+"&bkm="+bkm;
	//xmlHttp.onreadystatechange=stateChanged;
	xmlHttp.open("GET",sayfa,true);
	xmlHttp.send(null);	
	}
	
function kayitoku(kayitid,okunmadurum,kayitdurum,baslik,mod,durumbutton,bk,bkm){
	silbutton='';
	onaybutton='';
	if(kayitdurum!="2"){
	silbutton='<img src="images/sil.png" align="right" border="0" onclick="javascript:onayla('+"'"+'Silmek istediğinize emin misiniz?'+"'"+',kayitiptal,'+"'','include/kayitiptal.php?tid="+kayitid+",false,null',''"+');"/>"';	
	}
	if(kayitdurum=="3"){
	onaybutton='<img src="images/onay.png" align="right" border="0" onclick="javascript:ajaxverikaydet('+"'"+'include/kayitonayla.php?tid='+kayitid+"'"+',false,null);"/>"';	
	}
	if(okunmadurum=="2"){
	document.getElementById("baslik"+kayitid).innerHTML='<h3 onclick="javascript:kayitoku('+"'"+kayitid+"','1','"+kayitdurum+"','"+baslik+"','"+bk+"','"+bkm+')" style="cursor:pointer;background-color:#2c2c2b;border:1px solid #000000"><a class="normal"><img src="images/'+durumbutton+'" border="0">'+baslik+'</a>'+silbutton+onaybutton+'</h3>';
	kayitokuislem(kayitid,mod,bk,bkm);
	}
}
function suggestiongirisduzenle(aranacakyer,nesne){
	var deger='Search by location or hotel name';
	document.getElementById(nesne+"span").innerHTML='<input type="text" id="'+nesne+'" name="'+nesne+'" class="girisyazialani" onkeyup="javascript:lookup(this.value,'+"'"+nesne+"'"+')" value="'+deger+'"  onclick="javascript:textboxverikontrol('+"'"+nesne+"','Search by location or hotel name','tiklama'"+');" onblur="javascript:textboxverikontrol('+"'"+nesne+"','Search by location or hotel name','kontrol'"+');">';
	}
function fiyathesapla(durum,mod,dil){
	if(durum){
	document.getElementById('sistemmesaji').innerHTML='<a class="normalsiyah">Calculating...</a>';
	var gelentoplamkisi=0;
	var gidentoplamkisi=0;
	var donuyorlarmi=document.getElementById('isreturnresult').value;
	var gelenfrom=document.getElementById('frombolgeid').value;
	var gelento=document.getElementById('tobolgeid').value;
	var gidenfrom=0;
	var gidento=0;
	if(document.getElementById('dfrombolgeid').value.length>0){
		gidenfrom=document.getElementById('dfrombolgeid').value;
		}
	if(document.getElementById('dtobolgeid').value.length>0){
		gidento=document.getElementById('dtobolgeid').value;
		}
	gelentoplamkisi=document.getElementById('gkisisayi').options[document.getElementById('gkisisayi').selectedIndex].value;
	var gelenpaket=0;
	var gidenpaket=0;
	if(gelentoplamkisi<5 && gelentoplamkisi>0){
	gelenpaket=1;
	}
	else if(gelentoplamkisi>4 && gelentoplamkisi<8){
	gelenpaket=2;
	}
	else if(gelentoplamkisi>7 && gelentoplamkisi<14){
	gelenpaket=3;
	}
	else if(gelentoplamkisi>13 && gelentoplamkisi<28){
	gelenpaket=4;
	}
	if(donuyorlarmi==1){
	gidentoplamkisi=document.getElementById('dkisisayi').options[document.getElementById('dkisisayi').selectedIndex].value;
	if(gidentoplamkisi<5 && gidentoplamkisi>0){
	gidenpaket=1;
	}
	else if(gidentoplamkisi>4 && gidentoplamkisi<8){
	gidenpaket=2;
	}
	else if(gidentoplamkisi>7 && gidentoplamkisi<14){
	gidenpaket=3;
	}
	else if(gidentoplamkisi>13 && gidentoplamkisi<28){
	gidenpaket=4;
	}
	}
	//alert(gelenfrom+','+gelento+','+donuyorlarmi+','+gidenfrom+','+gidento+','+gelenpaket+','+gidenpaket+','+mod);
	transferfiyathesaplat(gelenfrom,gelento,donuyorlarmi,gidenfrom,gidento,gelenpaket,gidenpaket,mod);
	}
	else{
		if(dil==1){
	document.getElementById('sistemmesaji').innerHTML='Lütfen aşağıdakileri kontrol ediniz:<br><br>*Tüm zorunlu alanları doldurunuz.<br>*Lütfen transfer tarih ve zamanlarını doğru giriniz. <br>*Giriş yaptığınız tarih ve zamanla geçmişe ait olabilir ya da transferler arasında uyumsuz tarih aralığı olabilir.<br>*Geliş ve dönüş transferleri arasındaki tarih ve zamanlar farklı olmak zorundadır.';	
		}
		else{
			document.getElementById('sistemmesaji').innerHTML='Please check all these:<br><br>*Please fill all required fields.<br>*Please enter right date and time values for arrival transfer request.<br>*Please enter right date and time values for departure transfer request.<br>*The system does not accept previous date and time.<br>*Please enter different date or time between two transfers.';	
			}
	}
}
function fiyathesaplakayitduzelt(durum,mod,dil){
	if(durum){
	var gelentoplamkisi=0;
	var gidentoplamkisi=0;
	var donuyorlarmi=2;
	var gelenfrom=document.getElementById('frombolgeid').value;
	var gelento=document.getElementById('tobolgeid').value;
	var gidenfrom=0;
	var gidento=0;
	gelentoplamkisi=document.getElementById('gkisisayi').options[document.getElementById('gkisisayi').selectedIndex].value;
	var gelenpaket=0;
	var gidenpaket=0;
	if(gelentoplamkisi<5 && gelentoplamkisi>0){
	gelenpaket=1;
	}
	else if(gelentoplamkisi>4 && gelentoplamkisi<8){
	gelenpaket=2;
	}
	else if(gelentoplamkisi>7 && gelentoplamkisi<14){
	gelenpaket=3;
	}
	else if(gelentoplamkisi>13 && gelentoplamkisi<28){
	gelenpaket=4;
	}
	if(donuyorlarmi==1){
	gidentoplamkisi=0;
	if(gidentoplamkisi<5 && gidentoplamkisi>0){
	gidenpaket=1;
	}
	else if(gidentoplamkisi>4 && gidentoplamkisi<8){
	gidenpaket=2;
	}
	else if(gidentoplamkisi>7 && gidentoplamkisi<14){
	gidenpaket=3;
	}
	else if(gidentoplamkisi>13 && gidentoplamkisi<28){
	gidenpaket=4;
	}
	}
	//alert(gelenfrom+','+gelento+','+donuyorlarmi+','+gidenfrom+','+gidento+','+gelenpaket+','+gidenpaket+','+mod);
	transferfiyathesaplat(gelenfrom,gelento,donuyorlarmi,gidenfrom,gidento,gelenpaket,gidenpaket,mod);
	}
	else{
		if(dil==1){
	document.getElementById('sistemcevabi').innerHTML='Lütfen aşağıdakileri kontrol ediniz:<br><br>*Tüm zorunlu alanları doldurunuz.<br>*Lütfen transfer tarih ve zamanlarını doğru giriniz. <br>*Giriş yaptığınız tarih ve zamanla geçmişe ait olabilir ya da transferler arasında uyumsuz tarih aralığı olabilir.<br>*Geliş ve dönüş transferleri arasındaki tarih ve zamanlar farklı olmak zorundadır.';	
		}
		else{
			document.getElementById('sistemcevabi').innerHTML='Please check all these:<br><br>*Please fill all required fields.<br>*Please enter right date and time values for arrival transfer request.<br>*Please enter right date and time values for departure transfer request.<br>*The system does not accept previous date and time.<br>*Please enter different date or time between two transfers.';	
			}
	}
}
function transferfiyathesaplat(gelenfrom,gelento,donuyorlarmi,gidenfrom,gidento,gelenpaket,gidenpaket,mod){
	var xmlHttp;
try
  {
  // Firefox, Opera 8.0+, Safari
  xmlHttp=new XMLHttpRequest();
  }
catch (e)
  {
  // Internet Explorer
  try
    {
    xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
    }
  catch (e)
    {
    try
      {
      xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
      }
    catch (e)
      {
      alert("Kullandığınız web tarayıcısı AJAX Desteklememektedir.");
      return false;
      }
    }
  }
xmlHttp.onreadystatechange=function()
    {
    if(xmlHttp.readyState==4)
      {
	  var fiyatcevap=xmlHttp.responseText;
	  switch(mod){
		  case 1:
		  document.getElementById('gelenfiyat').innerHTML=fiyatlaricoz(fiyatcevap,1);
		  break;
		  case 2:
		  document.getElementById('gidenfiyat').innerHTML=fiyatlaricoz(fiyatcevap,2);
		  break;
		  case 3:
	  	  kalipyazdir(1,fiyatlaricoz(fiyatcevap,1),fiyatlaricoz(fiyatcevap,2),fiyatlaricoz(fiyatcevap,3));
		  break;
		  case 4:
		  document.getElementById('gelenfiyat').innerHTML=fiyatlaricoz(fiyatcevap,1);
		  break;
		  case 5:
		  document.getElementById('gidenfiyat').innerHTML=fiyatlaricoz(fiyatcevap,2);
		  break;
		  case 6:
	  	  kalipyazdir(2,fiyatlaricoz(fiyatcevap,1),fiyatlaricoz(fiyatcevap,2),fiyatlaricoz(fiyatcevap,3));
		  break;
		  case 7:
		  document.getElementById('gelenfiyat').innerHTML=fiyatlaricoz(fiyatcevap,1);
		  break;
		  case 8:
		  document.getElementById('gidenfiyat').innerHTML=fiyatlaricoz(fiyatcevap,2);
		  break;
		  case 9:
	  	  kalipyazdir(2,fiyatlaricoz(fiyatcevap,1),fiyatlaricoz(fiyatcevap,2),fiyatlaricoz(fiyatcevap,3));
		  break;
	  }
      }
    }
	if(mod==4 || mod==5 || mod==6){
	var sayfa="include/kurumsalfiyathesapla.php?uye="+document.getElementById('hangisite').value+"&gelenfromid="+gelenfrom+"&gelentoid="+gelento+"&isreturn="+donuyorlarmi+"&gidenfromid="+gidenfrom+"&gidentoid="+gidento+"&gelenpaket="+gelenpaket+"&gidenpaket="+gidenpaket;
	}
	else if(mod==7 || mod==8 || mod==9){
	var sayfa="include/acentafiyathesapla.php?uye="+document.getElementById('hangisite').value+"&gelenfromid="+gelenfrom+"&gelentoid="+gelento+"&isreturn="+donuyorlarmi+"&gidenfromid="+gidenfrom+"&gidentoid="+gidento+"&gelenpaket="+gelenpaket+"&gidenpaket="+gidenpaket;
	}
	else{
	var sayfa="include/fiyathesapla.php?gelenfromid="+gelenfrom+"&gelentoid="+gelento+"&isreturn="+donuyorlarmi+"&gidenfromid="+gidenfrom+"&gidentoid="+gidento+"&gelenpaket="+gelenpaket+"&gidenpaket="+gidenpaket;
	}

	//xmlHttp.onreadystatechange=stateChanged;
	xmlHttp.open("GET",sayfa,true);
	xmlHttp.send(null);	
}
function fiyatlaricoz(fiyat,hangisi){
	  var fiyatlar=fiyat.split('||');
	  switch(hangisi){
		case 1:
	  	return fiyatlar[0].toString();
		break;
		case 2:
	  	return fiyatlar[1].toString();
		break;
		case 3:
	  	return fiyatlar[2].toString();
		break;
	  }
}
function kalipyazdir(kalipno,arrivalfiyat,departurefiyat,toplamfiyat){
	var kalip='';
	var kalip1='';
	var kalip2='';
	var kalip3='';
	var kalip4='';
	var donuyorlarmi=document.getElementById('isreturnresult').value;
	var gelenfrom=document.getElementById('frombolgeisim').value;
	var frombolgeid=document.getElementById('frombolgeid').value;
	var gelentoid=document.getElementById('tobolgeid').value;
	var gelento=document.getElementById('tobolgeisim').value;
	var ucuskodu=document.getElementById('gucuskodu').value;
	var hangisite=document.getElementById('hangisite').value;
	var eposta=document.getElementById('eposta').value;
    var	gelentoplamkisi=document.getElementById('gkisisayi').options[document.getElementById('gkisisayi').selectedIndex].value;
	var tarih=document.getElementById('gtarihyil').options[document.getElementById('gtarihyil').selectedIndex].value+'-'+document.getElementById('gtarihay').options[document.getElementById('gtarihay').selectedIndex].value+'-'+document.getElementById('gtarihgun').options[document.getElementById('gtarihgun').selectedIndex].value;
	var saat=document.getElementById('gsaat').options[document.getElementById('gsaat').selectedIndex].value+':'+document.getElementById('gdak').options[document.getElementById('gdak').selectedIndex].value;
	var pickupsaat=document.getElementById('pickupsaat').options[document.getElementById('pickupsaat').selectedIndex].value+':'+document.getElementById('pickupdak').options[document.getElementById('pickupdak').selectedIndex].value;
	var isim=document.getElementById('isim').value
	var soyad=document.getElementById('soyad').value;
	var mesaj=document.getElementById('mesaj').value;
	mesaj=mesaj.replace(/\n/g,'');
	mesaj=mesaj.replace(/\r/g,'');
	mesaj=mesaj.replace("'","");
	var ducuskodu='';
	var gidentoplamkisi='';
	var gidenfrom=0;
	var gidento=0;
	var dtarih='';
	var dsaat='';
	var dpickupsaat='';
	var pickupkalip='';
	var dpickupkalip='';
	var pickupbulusma='';
	var	transferpickupbaslik='';
	var	departurepickupbaslik='';
	var arrivaltimebaslik='';
	var departuretimebaslik='';
	if(donuyorlarmi==1){
		gidenfrom=document.getElementById('dfrombolgeisim').value;
		gidento=document.getElementById('dtobolgeisim').value;
		ducuskodu=document.getElementById('ducuskodu').value;
		var dpickupsaat=document.getElementById('dpickupsaat').options[document.getElementById('dpickupsaat').selectedIndex].value+':'+document.getElementById('dpickupdak').options[document.getElementById('dpickupdak').selectedIndex].value;
		gidentoplamkisi=document.getElementById('dkisisayi').options[document.getElementById('dkisisayi').selectedIndex].value;
		dtarih=document.getElementById('dtarihyil').options[document.getElementById('dtarihyil').selectedIndex].value+'-'+document.getElementById('dtarihay').options[document.getElementById('dtarihay').selectedIndex].value+'-'+document.getElementById('dtarihgun').options[document.getElementById('dtarihgun').selectedIndex].value;
		dsaat=document.getElementById('dsaat').options[document.getElementById('dsaat').selectedIndex].value+':'+document.getElementById('ddak').options[document.getElementById('ddak').selectedIndex].value;
	}
	if(frombolgeid!=5 && frombolgeid!=4 && frombolgeid!=12){
		pickupkalip='<tr><td><a class="basliksiyah">Pick up time</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+pickupsaat+'</a></td></tr>';
		pickupbulusma='picked-up from';
		transferpickupbaslik='Departure Transfer Details';
		departurepickupbaslik='Arrival Transfer Details';
		arrivaltimebaslik='Departure Time';
		departuretimebaslik='Arrival Time';
		}
	else{
		dpickupkalip='<tr><td><a class="basliksiyah">Pick up time</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+dpickupsaat+'</a></td></tr>';
		pickupbulusma='met at';
		transferpickupbaslik='Arrival Transfer Details';
		departurepickupbaslik='Departure Transfer Details';
		arrivaltimebaslik='Arrival Time';
		departuretimebaslik='Departure Time';
		}
		switch(kalipno){
		case 1:
		var confverileri="'index.php?mid=78763984799879&dl=2&from="+gelenfrom+"&to="+gelento+"&isreturn="+donuyorlarmi+"&dfrom="+gidenfrom+"&dto="+gidento+"&kisi="+gelentoplamkisi+"&dkisi="+gidentoplamkisi+"&tarih="+tarih+"&dtarih="+dtarih+"&saat="+saat+"&dsaat="+dsaat+"&ucuskodu="+ucuskodu+"&ducuskodu="+ducuskodu+"&eposta="+eposta+"&isim="+isim+"&soyad="+soyad+"&arrivalfiyat="+arrivalfiyat+"&departurefiyat="+departurefiyat+"&toplamfiyat="+toplamfiyat+"&mesaj="+mesaj+"&arrivalpickup="+pickupsaat+"&departurepickup="+dpickupsaat+"&frombolgeid="+frombolgeid+"&hangisite="+hangisite+"&neredenbuldu="+document.getElementById('findus').options[document.getElementById('findus').selectedIndex].value+"'";
		var kalip1='<table cellpadding="0" cellspacing="0" border="0" width="95%" align="center"><tr><td><a class="basliksiyah">Dear  '+document.getElementById('isim').value+' '+document.getElementById('soyad').value+',</a></td></tr><tr><td height="20px"></td></tr><tr><td><a class="normalsiyah">Thank you very much for your inquiry. We will be very happy to help you with your transfer request.</a></td></tr><tr><td height="20px"></td></tr><tr><td><a class="normalsiyah">Please find our offer referring to your request below:</a></td></tr><tr><td height="20px"></td></tr><tr><td>';
		
		kalip2='<table cellpadding="0" cellspacing="0" border="0"><tr><td colspan="3"><a class="mavikalin">'+transferpickupbaslik+'</a></td></tr><tr><td><a class="basliksiyah">Transfer date</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('gtarihgun').options[document.getElementById('gtarihgun').selectedIndex].value+'-'+ingtarih(document.getElementById('gtarihay').options[document.getElementById('gtarihay').selectedIndex].value)+'-'+document.getElementById('gtarihyil').options[document.getElementById('gtarihyil').selectedIndex].value+'</a></td></tr><tr><td><a class="basliksiyah">Flight Code</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('gucuskodu').value+'</a></td></tr><tr><td><a class="basliksiyah">'+arrivaltimebaslik+'</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('gsaat').options[document.getElementById('gsaat').selectedIndex].value+':'+document.getElementById('gdak').options[document.getElementById('gdak').selectedIndex].value+'</a></td></tr><tr><td><a class="basliksiyah">Pick up from</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('frombolgeisim').value+'</a></td></tr>'+pickupkalip+'<tr><td><a class="basliksiyah">Transfer to</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('tobolgeisim').value+'</a></td></tr><tr><td><a class="basliksiyah">No of People</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('gkisisayi').options[document.getElementById('gkisisayi').selectedIndex].value+'</a></td></tr><tr><td><p align="justify"><a class="basliksiyah">Payment</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="fiyat">'+arrivalfiyat+' Eur</a></td></tr>';
		if(document.getElementById('isreturnresult').value==1){
		kalip3='<tr><td colspan="3" height="20px"></td></tr><tr><td colspan="3"><a class="mavikalin">'+departurepickupbaslik+'</a></td></tr><tr><td><a class="basliksiyah">Transfer date</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dtarihgun').options[document.getElementById('dtarihgun').selectedIndex].value+'-'+ingtarih(document.getElementById('dtarihay').options[document.getElementById('dtarihay').selectedIndex].value)+'-'+document.getElementById('dtarihyil').options[document.getElementById('dtarihyil').selectedIndex].value+'</a></td></tr><tr><td><a class="basliksiyah">Flight Code</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('ducuskodu').value+'</a></td></tr><tr><td><a class="basliksiyah">'+departuretimebaslik+'</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dsaat').options[document.getElementById('dsaat').selectedIndex].value+':'+document.getElementById('ddak').options[document.getElementById('ddak').selectedIndex].value+'</a></td></tr><tr><td><a class="basliksiyah">Pick up from</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dfrombolgeisim').value+'</a></td></tr>'+dpickupkalip+'<tr><td><a class="basliksiyah">Transfer to</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dtobolgeisim').value+'</a></td></tr><tr><td><a class="basliksiyah">No of People</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dkisisayi').options[document.getElementById('dkisisayi').selectedIndex].value+'</a></td></tr><tr><td><p align="justify"><a class="basliksiyah">Payment</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="fiyat">'+departurefiyat+' Eur</a></td></tr>';
		}
		kalip4='<tr><td colspan="3" height="20px"></td></tr><tr><td><a class="basliksiyah">Comment</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+mesaj+'</a></td></tr><tr><td colspan="3" height="20px"></td></tr><tr><td><p align="justify"><a class="basliksiyah">Total Payment</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="fiyat">'+toplamfiyat+' Eur</a></td></tr><tr><td colspan="3" align="left"><p align="justify"><a class="basliksiyah"><strong>24 Hours Available Contact Telephones :</strong><br/><strong>Telp No 1 :</strong> +90-212-638 63 43<br/><strong>Telp No 2 :</strong> +90-554-3638512</a></td></tr></table></td></tr><tr><td height="20px"></td></tr><tr><td><p align="justify"><a class="normalsiyah">You can pay in USD or TL as well. You can use the following link to convert the price quoted in Euro to the currency you want.</a>&nbsp;<a class="normalmavilink" href="http://www.tcmb.gov.tr/kurlar/today.html" target="_blank">Please click.</a><a class="normalsiyah">You can make the payment to your driver in cash change please, as the driver may not have change money with him.</p></a></td></tr><tr><td height="20px"></td></tr>';
		if(frombolgeid!=5 && frombolgeid!=4 && frombolgeid!=12){
		kalip5='<tr><td align="left"><p align="justify"><a class="normalsiyah">You will be picked up from '+document.getElementById('frombolgeisim').value+' and transferred directly to '+document.getElementById('tobolgeisim').value+'. We kindly request you to be ready 10 minutes before your departure time. We are very carefull to be on time, however if your driver will delay more then 5 minutes, please contact with us to check the final location of your vehicle.<br><br>We would like to remind you that you need to be at the airport 2 hours before for your international flight and 1.5 before your domestic flight. As you may face to a rush traffic on your way, we highly recommend you to leave some extra time on your departures against any delay.<br><br>As a usuall feature of our service standarts, you will be offered complimentary snacks during your journey, please enjoy it. You may contact with us through your driver'+"'"+'s cell phone for your any questions during the journey as well.<br><br>Payment can be done to the driver in cash change please, as the driver may not have change money with him. Please let us know in advance by e-mail or phone, if you will have a big banknot, so that we can have the driver enough cash money to give you the rest.<br><br>We also highly request you to inform us either by e-mail or phone in advance asap, if you will need to cancel your booking. That will prevent us to send you the vehicle for no use.</a></p></td></tr>';
		}
		else{
				if(frombolgeid==12){
				kalip5='<tr><td align="left"><p align="justify"><a class="normalsiyah">You will be met at the Cruise Port in the arrival hall by one of our colleagues whom will be holding a sign with your name and our agency name on it. You will be helped to load your luggage into the vehicle and transferred directly to '+document.getElementById('tobolgeisim').value+'.</a></p></td></tr><tr><td height="20px"></td></tr><tr><td align="center"><img src="images/karsilamacruiseport.jpg" border="0"></td></tr><tr><td height="20px"></td></tr><tr><td align="left"><p align="justify"><a class="normalsiyah">We kindly request you to be ready 10 minutes before your departure time. We are very carefull to be on time, however if your driver will delay more then 5 minutes, please contact with us to check the final location of your vehicle.<br><br> Your driver will offer you complimentary snacks & fruit juice to make the journey easier for you. Apart from the any other stories you may have heard, our drivers are polite and non-smoking, will not disturb you at the car with loud music, well dressed and follow the traffic rules strictly. Moreover, we follow up all our vehicles with a central GPRS system to check their speeds and locations. You will also have an additional benefit in our service comparing to taxis which is the fixed payment amount.</a></p></td></tr>';
				}
				else{
		kalip5='<tr><td align="left"><a class="normalsiyah"><p align="justify">You will be '+pickupbulusma+' '+document.getElementById('frombolgeisim').value+' by Backpackers Travel welcome staff and lead to our vehicle waiting for you outside. Upon clearing up your visa/custom process and picking up your luggages, please walk towards to exit door to get into to "Waiting Hall for The Arrivals". As soon as you get in to the hall, you will see the people waiting for their guests with the names in their hands. Backpackers Travel welcome staff will be waiting for you at the same spot as well. Please walk towards your left and look for a yellow tripod carrying the sign with our agency name on: Backpackers Travel.  Please contact with the staff waiting by the tripod either you see your name on it or not as they will be always willing to help you. Here is the tripod that you must search for:</a><p align="justify"></td></tr><tr><td height="20px"></td></tr><tr><td align="center"><img src="images/karsilama1.jpg" border="0">&nbsp;<img src="images/karsilamaekibi.jpg" border="0"></td></tr><tr><td height="20px"></td></tr><tr><td><p align="justify"><a class="normalsiyah">You may ask to our staff for your urgent needs at the airport such as changing money or buying a card for your mobile phone. They will be certainly pleased to help you.</a></td></tr><tr><td height="20px"></td></tr><tr><td><p align="justify"><a class="normalsiyah">Our drivers are very courteous and follow the traffic rules strictly. Moreover, we follow all our vehicles with a central GPRS system to check their speeds and locations. Additionally, all our drivers are non-smoker.</a></p></td></tr><tr>';
				}
		}
		kalip6='<td height="20px"></td></tr><tr><td><p align="justify"><a class="normalsiyah"><b>If you accept our offer and wish to confirm your reservation, please click the button below and an automatic confirmation e-mail will be sent to your e-mail address.</b></a></p></td></tr><tr><td height="20px"></td></tr><tr><td align="center"><input type="button" onclick="javascript:window.location='+confverileri+'" value="I want to confirm my reservation"></td></tr><tr><td height="20px"></td></tr><tr><td><p align="justify"><a class="normalsiyah">If you have any further questions and need to contact with us, please use the </a><a class="normalmavilink" href="http://www.ataturkairporttransfer.com/php/index.php?mid=66732848993276&mod=1&dl=2" target="_blank">contact form.</a></p></td></tr><tr><td class="onpixelyukseklik"></td></tr><tr><td align="left"><a class="normalsiyah"><strong>CONTACT DETAILS :</strong><br />Mr. Atilla CALISKAN<br />Travel Consultant<br />Backpackers Travel<br />Airport Transfer & City Tours Dept.<br />e-mail : transfer@ataturkairporttransfer.com<br /></a></td></tr><tr><td height="20px"></td></tr><tr><td><a class="normalsiyah">Backpackers Travel is always ready to make your trip easy and enjoyable.<br>You can contact with us for 24 hrs through the telephone no below:<br>Main Office: 0090-212-6386343 (08:00-23:00)<br>Night Office: 0090-212-6382563 (23:00-08:00)<br>Emergency Call: 0090-505-4362632 OR 0090-554-7392107</a></td></tr></table>';
		
		kalip=kalip1+kalip2+kalip3+kalip4+kalip5+kalip6;
		break;
		case 2:
		var pickupsaat=document.getElementById('gsaat').options[document.getElementById('gsaat').selectedIndex].value+':'+document.getElementById('gdak').options[document.getElementById('gdak').selectedIndex].value;
		var lastminute=document.getElementById('lastminute').value;
		confverileri="'index.php?mid=78763984799879&dl=2&from="+gelenfrom+"&to="+gelento+"&isreturn="+donuyorlarmi+"&dfrom="+gidenfrom+"&dto="+gidento+"&kisi="+gelentoplamkisi+"&dkisi="+gidentoplamkisi+"&tarih="+tarih+"&dtarih="+dtarih+"&saat="+saat+"&dsaat="+dsaat+"&ucuskodu="+ucuskodu+"&ducuskodu="+ducuskodu+"&eposta="+eposta+"&isim="+isim+"&soyad="+soyad+"&arrivalfiyat="+arrivalfiyat+"&departurefiyat="+departurefiyat+"&toplamfiyat="+toplamfiyat+"&mesaj="+mesaj+"&arrivalpickup="+pickupsaat+"&departurepickup="+dpickupsaat+"&frombolgeid="+frombolgeid+"&tobolgeid="+gelentoid+"&hangisite="+hangisite+"&last="+lastminute+"'";
			if(frombolgeid!=5 && frombolgeid!=4 && frombolgeid!=12){
		pickupkalip='<tr><td><a class="basliksiyah">Pick up Zamanı</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+pickupsaat+'</a></td></tr>';
		pickupbulusma='Yolcunun alınacağı yer';
		transferpickupbaslik='Çıkış Transfer Bilgileri';
		departurepickupbaslik='Varış Transfer Bilgileri';
		arrivaltimebaslik='Çıkış Zamanı';
		departuretimebaslik='Varış Zamanı';
		}
	else{
		dpickupkalip='<tr><td><a class="basliksiyah">Pick up Zamanı</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+dpickupsaat+'</a></td></tr>';
		pickupbulusma='Yolcunun alınacağı yer';
		transferpickupbaslik='Varış Transfer Bilgileri';
		departurepickupbaslik='Çıkış Transfer Bilgileri';
		arrivaltimebaslik='Varış Zamanı';
		departuretimebaslik='Çıkış Zamanı';
		}
		var kalip1='<table cellpadding="0" cellspacing="0" border="0" width="95%" align="center"><tr><td><a class="basliksiyah">'+document.getElementById('isim').value+' '+document.getElementById('soyad').value+' isimli müşterinin bilgileri aşağıdaki gibidir:</a></td></tr><tr><td height="20px"></td></tr><tr><td>';
		
		kalip2='<table cellpadding="0" cellspacing="0" border="0"><tr><td colspan="3"><a class="mavikalin">'+transferpickupbaslik+'</a></td></tr><tr><td><a class="basliksiyah">Transfer tarihi</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('gtarihgun').options[document.getElementById('gtarihgun').selectedIndex].value+'-'+ingtarih(document.getElementById('gtarihay').options[document.getElementById('gtarihay').selectedIndex].value)+'-'+document.getElementById('gtarihyil').options[document.getElementById('gtarihyil').selectedIndex].value+'</a></td></tr><tr><td><a class="basliksiyah">Uçuş kodu</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('gucuskodu').value+'</a></td></tr>';
		if(frombolgeid==5 || frombolgeid==4 || frombolgeid==12){
		kalip2=kalip2+'<tr><td><a class="basliksiyah">'+arrivaltimebaslik+'</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('gsaat').options[document.getElementById('gsaat').selectedIndex].value+':'+document.getElementById('gdak').options[document.getElementById('gdak').selectedIndex].value+'</a></td></tr>';
		}
		kalip2=kalip2+'<tr><td><a class="basliksiyah">Alınacağı yer</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('frombolgeisim').value+'</a></td></tr>'+pickupkalip+'<tr><td><a class="basliksiyah">Transfer Nereye</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('tobolgeisim').value+'</a></td></tr><tr><td><a class="basliksiyah">Yolcu sayısı</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('gkisisayi').options[document.getElementById('gkisisayi').selectedIndex].value+'</a></td></tr><tr><td><p align="justify"><a class="basliksiyah">Ödeme</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="fiyat">'+arrivalfiyat+' TL</a></td></tr>';
		if(document.getElementById('isreturnresult').value==1){
		kalip3='<tr><td colspan="3" height="20px"></td></tr><tr><td colspan="3"><a class="mavikalin">'+departurepickupbaslik+'</a></td></tr><tr><td><a class="basliksiyah">Transfer tarihi</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dtarihgun').options[document.getElementById('dtarihgun').selectedIndex].value+'-'+ingtarih(document.getElementById('dtarihay').options[document.getElementById('dtarihay').selectedIndex].value)+'-'+document.getElementById('dtarihyil').options[document.getElementById('dtarihyil').selectedIndex].value+'</a></td></tr><tr><td><a class="basliksiyah">Uçuş kodu</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('ducuskodu').value+'</a></td></tr><tr><td><a class="basliksiyah">'+departuretimebaslik+'</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dsaat').options[document.getElementById('dsaat').selectedIndex].value+':'+document.getElementById('ddak').options[document.getElementById('ddak').selectedIndex].value+'</a></td></tr><tr><td><a class="basliksiyah">Alınacağı yer</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dfrombolgeisim').value+'</a></td></tr>'+dpickupkalip+'<tr><td><a class="basliksiyah">Transfer Nereye</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dtobolgeisim').value+'</a></td></tr><tr><td><a class="basliksiyah">Yolcu sayısı</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+document.getElementById('dkisisayi').options[document.getElementById('dkisisayi').selectedIndex].value+'</a></td></tr><tr><td><p align="justify"><a class="basliksiyah">Ödeme</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="fiyat">'+departurefiyat+' TL</a></td></tr>';
		}
		kalip4='<tr><td colspan="3" height="20px"></td></tr><tr><td><a class="basliksiyah">Ek not</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="basliksiyah">'+mesaj+'</a></td></tr><tr><td colspan="3" height="20px"></td></tr><tr><td><p align="justify"><a class="basliksiyah">Toplam Ödeme</a></td><td class="bespixelgenislik"><a class="basliksiyah">:</a></td><td><a class="fiyat">'+toplamfiyat+' TL</a></td></tr></table></td></tr><tr><td height="20px"></td></tr><tr><td height="20px"></td></tr><tr><td align="center"><input type="button" onclick="javascript:yuklegoster();window.location='+confverileri+'" value="Rezervasyon bilgilerini onaylıyorum. Gönder."></td></tr>';
		kalip=kalip1+kalip2+kalip3+kalip4;
		break;
		case 3:
		break;
		}
document.getElementById('sistemmesaji').innerHTML=kalip;
	}
function formayarla(){
var gelenfromid=document.getElementById('frombolgeid').value;
if(gelenfromid!=5 && gelenfromid!=4 && gelenfromid!=12){
document.getElementById('arrivaldatesection').innerHTML='Departure Date';
document.getElementById('arrivaltimesection').innerHTML='Flight Departure Time';
//document.getElementById('arrivalflightsection').innerHTML='Departure Flight Code';
document.getElementById('departuredatesection').innerHTML='Arrival Date';
document.getElementById('departuretimesection').innerHTML='Arrival Time';
document.getElementById('departureflightsection').innerHTML='Arrival Flight Code';
document.getElementById('departurefromsection').innerHTML='Arrival Transfer From';
document.getElementById('departuretosection').innerHTML='Arrival Transfer To';
goster('arrivalpickuptimesection');
gizle('departurepickuptimesection');
}
else{
document.getElementById('arrivaldatesection').innerHTML='Arrival Date';
document.getElementById('arrivaltimesection').innerHTML='Arrival Time';
document.getElementById('arrivalflightsection').innerHTML='Arrival Flight Code';
document.getElementById('departuredatesection').innerHTML='Departure Date';
document.getElementById('departuretimesection').innerHTML='Flight Departure Time';
//document.getElementById('departureflightsection').innerHTML='Departure Flight Code';
document.getElementById('departurefromsection').innerHTML='Dep. Transfer From';
document.getElementById('departuretosection').innerHTML='Dep. Transfer To';
gizle('arrivalpickuptimesection');
goster('departurepickuptimesection');
}
}
function formayarlatranssoft(){
var gelenfromid=document.getElementById('frombolgeid').value;
if(gelenfromid!=5 && gelenfromid!=4 && gelenfromid!=12){
document.getElementById('arrivaldatesection').innerHTML='Gidiş Tarihi';
document.getElementById('arrivalflightsection').innerHTML='Giden Uçak Kodu';
document.getElementById('gucuskodu').value='xxx';
}
else{
document.getElementById('arrivaldatesection').innerHTML='Geliş Tarihi';
document.getElementById('arrivalflightsection').innerHTML='Gelen Uçak Kodu';
document.getElementById('gucuskodu').value='';
}
}
function formayarlatr(){
var gelenfromid=document.getElementById('frombolgeid').value;
if(gelenfromid!=5 && gelenfromid!=4 && gelenfromid!=12){
document.getElementById('arrivaldatesection').innerHTML='Gidiş Tarihi';
document.getElementById('arrivaltimesection').innerHTML='Pick up Zamanı';
document.getElementById('arrivalflightsection').innerHTML='Giden Uçak Kodu';
document.getElementById('gucuskodu').value='xxx';
document.getElementById('departuredatesection').innerHTML='Geliş Tarihi';
document.getElementById('departuretimesection').innerHTML='Geliş Zamanı';
document.getElementById('departureflightsection').innerHTML='Geliş Uçak Kodu';
document.getElementById('departurefromsection').innerHTML='Geliş Transfer Nereden';
document.getElementById('departuretosection').innerHTML='Geliş Transfer Nereye';
//goster('arrivalpickuptimesection');
//gizle('departurepickuptimesection');
}
else{
document.getElementById('arrivaldatesection').innerHTML='Geliş Tarihi';
document.getElementById('arrivaltimesection').innerHTML='Geliş Zamanı';
document.getElementById('arrivalflightsection').innerHTML='Geliş Uçak Kodu';
document.getElementById('gucuskodu').value='';
document.getElementById('departuredatesection').innerHTML='Gidiş Tarihi';
document.getElementById('departuretimesection').innerHTML='Giden Uçuş Zamanı';
document.getElementById('departureflightsection').innerHTML='Giden Uçak Kodu';
document.getElementById('departurefromsection').innerHTML='Giden Transfer Nereden';
document.getElementById('departuretosection').innerHTML='Giden Transfer Nereye';
//gizle('arrivalpickuptimesection');
//goster('departurepickuptimesection');
}
}
function tavsiyeedilenpickupzamani(dil){
	var gelentoid=document.getElementById('tobolgeid').value;
	var gelenfromid=document.getElementById('frombolgeid').value;
	var ucustipi=document.getElementById('ucustipideger').value;
	if(ucustipi==1){
	var gcikarilacaksaat=4;
	if(gelentoid==5){
	gcikarilacaksaat=3;
	}
	else if(gelentoid==4){
	gcikarilacaksaat=4;
	}
	else if(gelentoid==12){
	gcikarilacaksaat=3;
	}
	}
	else if(ucustipi==2){
	var gcikarilacaksaat=3;
	if(gelentoid==5){
	gcikarilacaksaat=2;
	}
	else if(gelentoid==4){
	gcikarilacaksaat=3;
	}
	else if(gelentoid==12){
	gcikarilacaksaat=2;
	}
	}
	var gidentoid=document.getElementById('dtobolgeid').value;
	var gidenfromid=document.getElementById('dfrombolgeid').value;
	var ducustipi=document.getElementById('ducustipideger').value;
	if(ducustipi==1){
	var dcikarilacaksaat=4;
	if(gidentoid==5){
	dcikarilacaksaat=3;
	}
	else if(gidentoid==4){
	dcikarilacaksaat=4;
	}
	else if(gidentoid==12){
	dcikarilacaksaat=3;
	}
	}
	else if(ducustipi==2){
	var dcikarilacaksaat=3;
	if(gidentoid==5){
	dcikarilacaksaat=2;
	}
	else if(gidentoid==4){
	dcikarilacaksaat=3;
	}
	else if(gidentoid==12){
	dcikarilacaksaat=2;
	}	
	}
	var gsaat=document.getElementById('gsaat').options[document.getElementById('gsaat').selectedIndex].value;
	saatbulfarki=gsaat-gcikarilacaksaat;
	var saat=saatbulfarki;
	if(saatbulfarki<0){
	saat=24-(saatbulfarki*-1);
	}
	saatkelimesayisi=saat.length;
	if(saatkelimesayisi==1){
		saat='0'+saat;
		}
		if(gelentoid.length>0){
			if(dil==1){
	document.getElementById('suggestedpickuptime').innerHTML='Tavsiye edilen Pick-up Zamanı: '+saat+':'+document.getElementById('gdak').options[document.getElementById('gdak').selectedIndex].value;
			}
			else{
	document.getElementById('suggestedpickuptime').innerHTML='Recommended Pick-up Time: '+saat+':'+document.getElementById('gdak').options[document.getElementById('gdak').selectedIndex].value;
				}
		}
	var dsaat=document.getElementById('dsaat').options[document.getElementById('dsaat').selectedIndex].value;
	saatbulfarki=dsaat-dcikarilacaksaat;
	var saat=saatbulfarki;
	if(saatbulfarki<0){
	saat=24-(saatbulfarki*-1);
	}
	saatkelimesayisi=saat.length;
	if(saatkelimesayisi==1){
		saat='0'+saat;
	}
	if(gidentoid.length>0){
		if(dil==1){
	document.getElementById('dsuggestedpickuptime').innerHTML='Tavsiye edilen Pick-up Zamanı: '+saat+':'+document.getElementById('ddak').options[document.getElementById('ddak').selectedIndex].value;
		}
		else{
	document.getElementById('dsuggestedpickuptime').innerHTML='Recommended Pick-up Time: '+saat+':'+document.getElementById('ddak').options[document.getElementById('ddak').selectedIndex].value;
			}
	}
}
