function SearchBoxFunction()
{
	$("fromIata").addEvent('click',function(){
		$("fromIata").value="";
	});
	
	$("toIata").addEvent('click',function(){
		$("toIata").value="";
	});
	$('prefAirline').addEvent('change',function(){
		if($('prefAirline') && ($('prefAirline').value=="" ||$('prefAirline').value==null))
		{
			$('airlinexid').value='*';
		}
	});
	
}

function createBookInterstetial(){

	$$('div.ibe-adminstyle-alwayshidden').set('style','');
	$('interstetialpage').removeClass('onlyinvisible');
	
}

function createModifyInterstetial(){
	
	var parentDiv = $('interstetialpage').getParent();
	parentDiv.set('style','');
	
	if($('onwardtripradio').checked){
		$('airDepart').set('html','Depart:&nbsp;'+$('fromdate').get('value'));
		$('airDepart').setProperty('colspan','3');
		$('airReturn').set('html','');
	}else{
		$('airDepart').set('html','Depart:&nbsp;'+$('fromdate').get('value'));
		$('airReturn').set('html','Return:&nbsp;'+$('returndate').get('value'));
		$('airDepart').setProperty('colspan','');
	}
	
	$('airFromIata').set('html','Origin:&nbsp;'+$('fromIata').get('value'));
	$('airToIata').set('html','Destination:&nbsp;'+$('toIata').get('value'));
	
	
	$$('div.ibe-adminstyle-alwayshidden').set('style','');
	$('interstetialpage').removeClass('onlyinvisible');
	
}

window.addEvent(EnvVariables.LOAD_METHOD,SearchBoxFunction);