	document.write("<style type=\"text/css\">@import url(http://bookengine.hotelsearch.com/mre/css/astotel_new.css);<"+"/style>");
			document.write("<style type=\"text/css\">@import url(http://bookengine.hotelsearch.com/mre/css/frame_smallcc.css);<"+"/style>");
	

var mreservation_Init=function() {												
	fr = new mirai.mreservation(request);	
}	

function mreservation_Load() {
	var myConfig={		
		prefix: "http://bookengine.hotelsearch.com/javascript/mirai/",	
		prefixDojo: "http://bookengine.hotelsearch.com/javascript/dojoxd/",
		depsMirai: ['mreservation'],
		loadDojo: true,
		depsDojo: ['date', 'style', 'io', 'io.ScriptSrcIO', 'lfx.html'],
		callback: mreservation_Init, 
		checkBodyLoaded: true
	};
	
	try {
		MiraiConfig=MiraiConfig;
		try {			
			mirai.appendConfig(myConfig);			
		}	
		catch(e) {
			setTimeout("mreservation_Load()", 300);
		}
	}
	catch (e) {		
		MiraiConfig=myConfig;					
		document.write("<script type=\"text/javascript\" src=\"http://bookengine.hotelsearch.com/javascript/mirai/mirai_standard.js\"><"+"/script>");
	}	
}

var request = { where : 'framereservation',
				id : 14693277,
				language : 'en',
				skin : 'small2',
				css : 'astotel_new.css',					
								hsri : '02040',				startNights: 0,
				mc: '0',				
								
				show_messages: 1,
				target: '_blank',
				engine: 'MRE',
				domainName: 'secure.hotelsearch.com'	
				};
if (!request.where) request.where="frame";

if (!document.getElementById(request.where)) {
   alert("Not found: " + request.where);
} else {
   divHtml='<div id=\"mreLoader\" class=\"small\">	<div id=\"frame_bookingArea\">		<div id=\"frame_checkinContainer\" onclick=\"fr.showCalendar()\" class=\"frame_text\">			<span class=\"checkinName\"> Check-in:</span>			<div id=\"frame_checkinContents\">				<span id=\"frame_date\" class=\"frame_txtinput\" >					<span id=\"frame_checkin\" ></span>				</span>			</div>		</div>		<div id=\"frame_nightsContainer\" class=\"frame_text\">			<span class=\"checkinName\"> Nights:</span>			<div id=\"frame_nightsContents\">				<span id=\"frame_nights\">				</span>			</div>		</div>		<div id=\"frame_checkoutContainer\" class=\"frame_text\">			<span class=\"checkinName\" style=\"margin-top:-3px;\"> Promotional code:</span>			<span id=\"frame_clientcode\" class=\"frame_txtinput\"></span>		</div>		<div id=\"frame_buttonBookContainer\">			<input value=\" Check Rates and Book\" onclick=\"fr.book();\" id=\"frame_buttonBook\" class=\"frame_buttonBook_en\" type=\"button\" />		</div>	</div>	<div id=\"frame_buttonCancelContainer\"><a href=\"javascript:;\" onclick=\"fr.track();\" id=\"frame_buttonCancel\" class=\"frame_text\"> Track/Cancel Reservation</a>	</div></div>';
   if ( divHtml != "" ) {
       document.getElementById(request.where).innerHTML = "<div id=\"frame_loading\">Loading</div>";
       mreservation_Load();	
   } else {
       var widg;
       if (request.skin == 'small2') request.skin = 'small';
       if (request.engine == "XMAS" || request.engine == "BOOKING" ) {
           var res = (request.language == "es") ? "<h2>RESERVAR</h2>" : "<h1>RESERVE</h2>";
           var mloc = "https://" + request.domainName + "/XMAS/Booking.html?hotel=" + request.id;
           if (request.hsri) mloc += "&hsri=" + request.hsri;
	   widg = "<a href=\"" + mloc + "\" target=\"_blank\">" + res + "</a>";
       } else {
           var mloc = "http://bookengine.hotelsearch.com/mre/php/Frame.php?idtokenprovider=" + request.id 
                    + "&language=" + request.language + "&type=" + request.skin + "&domain=" + request.domainName;
           if (request.hsri) mloc += "&hsri=" + request.hsri;

           widg = "<iframe src=\"" + mloc + "\" frameborder=\"0\" scrolling=\"auto\" " + 
                  "style=\"height: 100%; width: 100%; margin-left: auto; margin-right: auto;\"></iframe>";
       }
       document.getElementById(request.where).innerHTML = widg;
   }
}
