//' Web software by DavidRegier.com: Fact Sheet Code

/*
function actFakeLink
function collapse
function deActivateFakeLink
function expand
function getCalPopUpLink
function section
*/

y = 1;

gVillaRecNum = -1;
List = new Listings();

PF = new PrinterFriendly();

initFactSheetData();

//////////////////////////////////// Fact Sheet Object Constructor ////////////////////////////////////

function FactSheet() {

	this.writeFS = writeFS;
	this.writeTestimonial = writeTestimonial;

	//--------------------------------------------------------------------------------------

	function getCalPopUpLink() {

		return ( CALENDAR_RECORDS_HT[ Villas[ gVillaRecNum ][ 0 ] ] && CALENDAR_RECORDS_HT[ Villas[ gVillaRecNum ][ 0 ] ][ 5 ] == 1 || ( CALENDAR_RECORDS_HT[ Villas[ gVillaRecNum ][ 0 ] ] && CALENDAR_RECORDS_HT[ Villas[ gVillaRecNum ][ 0 ] ][ 5 ] && staffUser && CALENDAR_RECORDS_HT[ Villas[ gVillaRecNum ][ 0 ] ][ 5 ] != 4 ) ) ? "<SPAN CLASS='on'><DIV CLASS='vSpacer5'> &nbsp;</DIV><NOBR>• <A HREF='javascript:PopUp.openWin(\"calendar-villa.html?" + qStr + "&CONTEXT=popup\", 1 );' onMouseOver='self.status = dText[ 32 ]; this.title = dText[ 32 ]; return true;' onMouseOut='self.status=\"\"; return true;' CLASS='fSize9'>See Calendar</A></NOBR><BR></SPAN>" : "";

	}
	//--------------------------------------------------------------------------------------

	function writeFS() {

		if( validDataSrc ) {

			if( gVillaRecNum >= 0 ) {

				if( Villas[ gVillaRecNum ][ 17 ] == "" ) {

					document.write( getVillaName( " &gt; Rates & Details" ) );
					var nCell = "<TD WIDTH=25% VALIGN=top ALIGN=right CLASS=lgBoldWhBkgBlue>";
					var vCell = "<TD WIDTH=25% VALIGN=top CLASS=lgWhBkgBlue>";
					var vSpacer = "<TR><TD COLSPAN=4 HEIGHT=4></TD></TR>";
					var bdDet = "Click to Show Bedroom Details";
					var bdrmHTML = "";

					var vName = Villa.Name[ 1 ].toUpperCase();
					changeTitle( vName );

					// Iterate through all 10 bdrms & only show bdrms that exist...
					for( var i = 1; i <= 10; i++ ) {

						if( eval( "Villa.Bd" + i + "_Bed" ) ) {

							var bedNum = i;

							var name = "Bed #"; if( bedNum == 1 ) { name = "Master Bed"; bedNum = ""; }

							bdrmHTML += '' +
							"<TABLE WIDTH=100% ALIGN=center BORDER=0 CELLSPACING=2 CELLPADDING=0>" +
								"<TR>" +
									"<TD>" +
							"<TABLE WIDTH=100% ALIGN=center BORDER=0 CELLSPACING=2 CELLPADDING=5>" +

								"<TR>" +
									nCell +
										name + bedNum + " Type " +
									"</TD>" +
									vCell +
										eval("Villa.Bd" + i + "_Bed") +
									"</TD>" +
									nCell +
										name + bedNum + " View " +
									"</TD>" +
									vCell +
										eval("Villa.Bd" + i + "_View") +
									"</TD>" +
								"</TR>" +

								"<TR>" +
									nCell +
										name + bedNum + " Bathroom " +
									"</TD>" +
									vCell +
										eval("Villa.Bd" + i + "_Bath") +
									"</TD>" +
									nCell +
										name + bedNum + " Floor " +
									"</TD>" +
									vCell +
										eval("Villa.Bd" + i + "_Floor") +
									"</TD>" +
								"</TR>" +

								"<TR>" +
									nCell +
										name + bedNum + " <NOBR>Closet(s)</NOBR> " +
									"</TD>" +
									vCell +
										eval("Villa.Bd" + i + "_Closet") +
									"</TD>" +
									nCell +
										name + bedNum + " Patio/Lanai " +
									"</TD>" +
									vCell +
										eval("Villa.Bd" + i + "_PatLanai") +
									"</TD>" +
								"</TR>" +

								"<TR>" +
									nCell +
										name + bedNum + " Electronics &amp; Entertainment " +
									"</TD>" +
									vCell +
										eval("Villa.Bd" + i + "_Electronics") +
									"</TD>" +
									nCell +
										name + bedNum + " AC " +
									"</TD>" +
									vCell +
										eval("Villa.Bd" + i + "_AC") +
									"</TD>" +
								"</TR>" +

							"</TABLE>" +
									"</TD>" +
								"</TR>" +
							"</TABLE>";

						}
					}

					if( bdrmHTML == "" ) {
					bdrmHTML = "" +
					"<TABLE WIDTH=100% ALIGN=center BORDER=0 CELLSPACING=2 CELLPADDING=0>" +
						"<TR>" +
							"<TD>" +
								"<TABLE WIDTH=100% ALIGN=center BORDER=0 CELLSPACING=2 CELLPADDING=5>" +
									"<TR>" +
										"<TD COLSPAN=4 WIDTH=100% VALIGN=top ALIGN=center CLASS=normWh>" +
											"&#151; No Bedroom Details Presently Available &#151;" +
										"</TD>" +
									"</TR>" +
								"</TABLE>" +
							"</TD>" +
						"</TR>" +
					"</TABLE>";
					}

					var fs = "<SPAN CLASS='on' ID='lineBreaks'><BR></SPAN>" +

					"<DIV ID=pfTitle CLASS='off' STYLE='color:black; font-size:12pt; font-weight:normal;'></DIV>" +

					"<TABLE WIDTH=80% ALIGN=center BORDER=0 CELLSPACING=0 CELLPADDING=0 class='tableGrid'>" +
						"<TR>" +
							"<TD>" +
								"<a name=External></a>" +
					"<TABLE WIDTH=100% ALIGN=center BORDER=0 CELLSPACING=2 CELLPADDING=5>" +

						"<TR>" +
							"<TD ALIGN=center COLSPAN=4 CLASS=lgBoldWhBkgBlue>" +
								vName +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							"<TD COLSPAN=4 CLASS=lgWhBkgBlue>" +
								Villa.Commentary +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Setting " +
							"</TD>" +
							vCell +
								Villa.Setting[ 1 ] +
							"</TD>" +
							nCell +
								"Location " +
							"</TD>" +
							vCell +
								Villa.Loc[ 1 ] +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Island " +
							"</TD>" +
							vCell +
								Villa.Island[ 1 ] +
							"</TD>" +
							nCell +
								"View " +
							"</TD>" +
							vCell +
								Villa.View +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Bedrooms " +
							"</TD>" +
							vCell +
								Villa.Bdrm[ 1 ] +
							"</TD>" +
							nCell +
								"Bathrooms " +
							"</TD>" +
							vCell +
								Villa.Bath[ 1 ] +
							"</TD>" +
						"</TR>" +

						vSpacer +

						"<TR>" +
							nCell +
								" RATES " +
							"</TD>" +
							vCell +
								Villa.Rate[ 1 ] +
							"</TD>" +
							nCell +
								" Availability " +
								getCalPopUpLink() +
							"</TD>" +
							vCell +
								Villa.Availability +
							"</TD>" +
						"</TR>" +

						vSpacer +

						"<TR>" +
							nCell +
								"National Holiday Rate " +
							"</TD>" +
							vCell +
								Villa.RateNatHol +
							"</TD>" +
							nCell +
								"Christmas &amp; New Year Rate " +
							"</TD>" +
							vCell +
								Villa.RateXmasNy +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Other Rate Variations " +
							"</TD>" +
							vCell +
								Villa.RateOtherVar +
							"</TD>" +
							nCell +
								"Minimum Stay " +
							"</TD>" +
							vCell +
								Villa.MinStay +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Maximum Occupancy Including Children " +
							"</TD>" +
							vCell +
								Villa.MaxOcc[ 1 ] +
							"</TD>" +
							nCell +
								"Security, Damage &amp; Incidentals Deposit " +
							"</TD>" +
							vCell +
								Villa.Deposit +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Initial Reservation Payment " +
							"</TD>" +
							vCell +
								Villa.InitialPay +
							"</TD>" +
							nCell +
								"Final Reservation Payment " +
							"</TD>" +
							vCell +
								Villa.FinalPay +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Outcleaning Charge " +
							"</TD>" +
							vCell +
								Villa.OutClean +
							"</TD>" +
							nCell +
								"Housekeeping Services Provided " +
							"</TD>" +
							vCell +
								Villa.HsKpProvided +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Extra Housekeeping Cost " +
							"</TD>" +
							vCell +
								Villa.HsKpProvidedXtra +
							"</TD>" +
							nCell +
								"&nbsp;" +
							"</TD>" +
							vCell +
								"&nbsp;" +
							"</TD>" +
						"</TR>" +

						vSpacer +

						"<TR>" +
							nCell +
								"Check In Time " +
							"</TD>" +
							vCell +
								Villa.CheckIn +
							"</TD>" +
							nCell +
								"Check Out Time " +
							"</TD>" +
							vCell +
								Villa.CheckOut +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Beach Access " +
							"</TD>" +
							vCell +
								Villa.BeachAccess +
							"</TD>" +
							nCell +
								"Ocean Access " +
							"</TD>" +
							vCell +
								Villa.OceanAccess +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Pool " +
							"</TD>" +
							vCell +
								Villa.Pool[ 1 ] +
							"</TD>" +
							nCell +
								"Heated Pool " +
							"</TD>" +
							vCell +
								Villa.PoolHeat +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Indoor Spa " +
							"</TD>" +
							vCell +
								Villa.SpaIndoor +
							"</TD>" +
							nCell +
								"Outdoor Spa " +
							"</TD>" +
							vCell +
								Villa.SpaOutdoor +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Central AC " +
							"</TD>" +
							vCell +
								Villa.AC_Central +
							"</TD>" +
							nCell +
								"Partial AC " +
							"</TD>" +
							vCell +
								Villa.AC_Partial +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"BBQ " +
							"</TD>" +
							vCell +
								Villa.BBQ +
							"</TD>" +
							nCell +
								"Security System " +
							"</TD>" +
							vCell +
								Villa.SecSys +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Parking " +
							"</TD>" +
							vCell +
								Villa.Parking +
							"</TD>" +
							nCell +
								"Vehicles Allowed " +
							"</TD>" +
							vCell +
								Villa.NumCars +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Cable TV " +
							"</TD>" +
							vCell +
								Villa.CableTV +
							"</TD>" +
							nCell +
								"Satellite TV " +
							"</TD>" +
							vCell +
								Villa.SatTV +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Indoor Dining " +
							"</TD>" +
							vCell +
								Villa.DineIn +
							"</TD>" +
							nCell +
								"Outdoor Dining " +
							"</TD>" +
							vCell +
								Villa.DineOut +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Approx Interior Size " +
							"</TD>" +
							vCell +
								Villa.HomeSize +
							"</TD>" +
							nCell +
								"Approx Lot Size " +
							"</TD>" +
							vCell +
								Villa.LotSize +
							"</TD>" +
						"</TR>";

						var disclosures = Villa.Disclosure;

						if( Villa.Disclosure ) {

							fs +=
							"<TR>" +
								"<TD ALIGN=center COLSPAN=4 CLASS=lgWhBkgBlue>" +
									"VILLA SPECIFIC DISCLOSURES" +
								"</TD>" +
							"</TR>" +

							"<TR>" +
								"<TD COLSPAN=4 CLASS=lgWhBkgBlue>" +
									Villa.Disclosure +
								"</TD>" +
							"</TR>";
						}

						fs +=

						"<TR CLASS='onP'>" +
							"<TD ALIGN=center COLSPAN=4 CLASS=lgBoldWhBkgBlue>" +

								"<span class='diPlusMinus'>+</span><a href='javascript:void(0);' onClick='if( window.DI ) DI.switchDisplay( this, \"bed_details\", \"focus_bed_details\" );' onMouseover='if( window.DI ) DI.showTip( this ); return true;' onMouseout='self.status=\"\"; return true;' class='diHeading'>View Bedroom Details</a>" +


							"</TD>" +
						"</TR>" +

							"</TD>" +
						"</TR>" +
					"</TABLE>" +

							"</TD>" +
						"</TR>" +
					"</TABLE>" +

					// BEDROOMS

					"<div class='diContent' ID='content_bed_details'>" +
						"<TABLE WIDTH=80% ALIGN=center BORDER=0 CELLSPACING=0 CELLPADDING=0>" +
							"<TR>" +
								"<TD>" +
									"<TABLE ALIGN=center BORDER=0 CELLSPACING=0 CELLPADDING=0 CLASS='tableGrid'>" +
										"<TR>" +
											"<TD>" +
												bdrmHTML +
											"</TD>" +
										"</TR>" +
									"</TABLE>" +
								"</TD>" +
							"</TR>" +
						"</TABLE>" +
					"</div>" +


					"<div id='focus_bed_details'></div><BR>" +

					// REMAINING INFO

					"<TABLE WIDTH=80% ALIGN=center BORDER=0 CELLSPACING=0 CELLPADDING=0 class='tableGrid'>" +
						"<TR>" +
							"<TD>" +
					"<TABLE WIDTH=100% ALIGN=center BORDER=0 CELLSPACING=2 CELLPADDING=5>" +
						"<TR>" +
							"<TD ALIGN=center COLSPAN=4 CLASS=lgWhBkgBlue>" +
								"OTHER NON-STANDARD AMENITIES PROVIDED IN THIS VILLA" +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Personal Safe " +
							"</TD>" +
							vCell +
								Villa.Safe +
							"</TD>" +
							nCell +
								"Fireplace " +
							"</TD>" +
							vCell +
								Villa.FirePl +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Living Room Sofa Bed " +
							"</TD>" +
							vCell +
								Villa.LivRmSofaBed +
							"</TD>" +
							nCell +
								"DVD " +
							"</TD>" +
							vCell +
								Villa.DVD +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"DVD Library " +
							"</TD>" +
							vCell +
								Villa.DVD_Library +
							"</TD>" +
							nCell +
								"Video Library " +
							"</TD>" +
							vCell +
								Villa.VCR_Library +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Gym " +
							"</TD>" +
							vCell +
								Villa.Gym +
							"</TD>" +
							nCell +
								"Billiard Table " +
							"</TD>" +
							vCell +
								Villa.BilliardTable +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Internet Connection " +
							"</TD>" +
							vCell +
								Villa.Internet +
							"</TD>" +
							nCell +
								"Office " +
							"</TD>" +
							vCell +
								Villa.Office +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Wine Fridge " +
							"</TD>" +
							vCell +
								Villa.WineRefer +
							"</TD>" +
							nCell +
								"CD Clock Radio " +
							"</TD>" +
							vCell +
								Villa.ClockRadio +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Down Pillows " +
							"</TD>" +
							vCell +
								Villa.DownPillow +
							"</TD>" +
							nCell +
								"Home Theater Room " +
							"</TD>" +
							vCell +
								Villa.Theatre +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Tiki Torches " +
							"</TD>" +
							vCell +
								Villa.TikiTorch +
							"</TD>" +
							nCell +
								"Bath Robes " +
							"</TD>" +
							vCell +
								Villa.BathRobe +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Picnic Basket/Cooler " +
							"</TD>" +
							vCell +
								Villa.PicnicBasketCooloer +
							"</TD>" +
							nCell +
								"Hammock " +
							"</TD>" +
							vCell +
								Villa.Hammock +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							nCell +
								"Shaded Outdoor Dining " +
							"</TD>" +
							vCell +
								Villa.ShadedOutdoorDining +
							"</TD>" +
							nCell +
								"Bottled Water Cooler/Dispenser " +
							"</TD>" +
							vCell +
								Villa.Water +
							"</TD>" +
						"</TR>" +

						"<TR>" +
							"<TD COLSPAN=1 VALIGN=top ALIGN=right CLASS=lgBoldWhBkgBlue>" +
								"Other Non-Standard Amenities Provided in this Villa:" +
							"</TD>" +
							"<TD COLSPAN=3 VALIGN=top CLASS=lgWhBkgBlue>" +
								Villa.OtherAmenities +
							"</TD>" +
						"</TR>" +


					"</TABLE>" +
						"</TD>" +
					"</TR>" +

					"</TABLE><BR>" +

					"<DIV><SPAN CLASS=yel>&#149; </SPAN><A HREF='javascript:void( 0 );' onMouseOver='self.status=this.title; return true;' onMouseOut='self.status=\"\"; return true;' onClick='getTravelAgent(); PF.setView( this, [\"page_top\",\"pLinks\",\"lineBreaks\",\"page_bottom\"], [\"tableGrid\", \"lgBoldWhBkgBlue\", \"lgWhBkgBlue\", \"normBoldBkgBlue\", \"normBkgBlue\"], true ); PF.printPage( this );' onContextMenu='PF.setView( this, [\"page_top\",\"pLinks\",\"lineBreaks\",\"page_bottom\"], [\"tableGrid\", \"lgBoldWhBkgBlue\", \"lgWhBkgBlue\", \"normBoldBkgBlue\", \"normBkgBlue\"], true ); return false;' TITLE='" + PF.dText[ 2 ] + "' ID='prnFrLink'>" + PF.dText[ 0 ] + "</A></DIV>";

					var fileName = "unknown";
					if( qStr ) fileName = qStr.getVal( "data" );
					document.write( fs );
				}
				else { // Data outsourced from external web site

					htm =

					"<style>.StdLanguageDiv{ display:none;}</style>" +

					"<div style='width:90%; text-align:left; font-size:12pt;'>" + Villa.Commentary + "</div>" +

					"<a name=External></a>" +

					"<div style='margin:10px 0px 15px 0px;'>" +
						"<iframe src='" + Villas[ gVillaRecNum ][ 17 ] + "' width='85%' height='80%' frameborder='0' scrolling='yes' marginheight='0' marginwidth='0' align='top'></iframe>" +
					"</div>";

					document.write( htm );

				}
			}
			else {

				htm =

				"<style>.StdLanguageDiv{ display:none;}</style>" +

				"<div class='fSize12' style='width:600px; text-align:left; margin:10px 0px 20px 0px;'><b>Sorry</b>, we are not maintaining fact sheet data for this property. If you feel that you have reached this message in error, please <a href='javascript:reportError( \"TVV Fact Sheet Data Error\", \"Cannot find a match in the listings.js file for property with id \\&#34;" + dataFile.substring( 11, dataFile.length - 3 )  + "\\&#34;\" );' style='font-size:12pt; white-space:nowrap;'>Report this problem</a> to our Web Site Administrator.</div>";

				document.write( htm );

			}


		}

		document.write("<DIV CLASS=" + pageBotCls + " ID=page_bottom>");

	}

	//--------------------------------------------------------------------------------------

	function writeTestimonial() {

		writeSummaryLinks( "fs" );
		changeTitle( Villa.Name[ 1 ] );

		if( Villa.Testimonials ) {

			var htm = "" +

			"<TABLE ALIGN=center BORDER=0 CELLSPACING=0 CELLPADDING=1 BGCOLOR=#314de7 WIDTH=90%>" +
				"<TR>" +
					"<TD>" +
						"<TABLE BORDER=0 CELLPADDING=8 CELLSPACING=0 BGCOLOR=#0000cc WIDTH=100%>" +
							"<TR>" +
								"<TD ALIGN=center CLASS=normBold>" +
								"&#151; Comments from Satisfied Guests of " + Villa.Name[ 1 ] +
								" &#151;</TD>" +
							"</TR>" +

							"<TR>" +
								"<TD CLASS=fSize10><BR>" +

									Villa.Testimonials +

								"</TD>" +
							"</TR>" +
						"</TABLE>" +
					"</TD>" +
				"</TR>" +
			"</TABLE>";

			document.write( htm );

		}

	}
}

FS = new FactSheet();