// --------------------------------------------------------------------------------
// main.js
// --------------------------------------------------------------------------------
// description - outputs common elements of the website
// --------------------------------------------------------------------------------


// function :: writeHeader( target)
// --------------------------------------------------------------------------------
// target - Name of the page that matches to the menu 'if' statements.
// --------------------------------------------------------------------------------
function writeHeader( target, background )
{
	document.write( "	<!--- MAIN TABLE --- START --->" );
	document.write( "	<table cellSpacing='0' cellPadding='0' width='800' align='center' border='0'>" );
	document.write( "		<tr>" );
	document.write( "			<!--- HEADER - BANNER --->" );
	document.write( "			<td width='800'><img src='images/header-left.jpg' border='0'><a href='http://www.olhomes.ca/thinkingofgoinggreen.html'><img src='images/header-right.jpg' border='0'></a><td>" );
	document.write( "		</tr>" );
	document.write( "		<tr>" );
	document.write( "			<td width='800'>" );
	document.write( "				<!--- MENU --->" );
	document.write( "				<table cellSpacing='0' cellPadding='0' width='800' align='center' border='0'>" );
	document.write( "					<tr>" );
	document.write( "						<td width='114'><img src='images/menuBuffer.jpg' border='0'></td>" );
	document.write( "						<td width='686'>" );
	document.write( "							<table cellSpacing='0' cellPadding='0' width='686' align='center' border='0'>" );
	document.write( "								<tr>" );
	document.write( "									<td width='686' height='1' class='pageBorder'></td>" );
	document.write( "								</tr>" );
	document.write( "								<tr>" );
	document.write( "									<td width='686' height='26' class='menu'>" );
	document.write( "										&nbsp;" );
	document.write( "										<a href='index.html' class='linkDefault'>Home</a> &nbsp;&nbsp;&nbsp; " );
	document.write( "										<a href='floorPlans.html' class='linkDefault'>Floor Plans</a> &nbsp;&nbsp;&nbsp;" );
	document.write( "										<a href=\"index.html\" onClick=\"return clickreturnvalue()\" onMouseover=\"dropdownmenu(this, event, packages, '135px')\" onMouseout=\"delayhidemenu()\" class=\"linkDefault\">Packages</a> &nbsp;&nbsp;&nbsp;" );
	document.write( "										<a href=\"index.html\" onClick=\"return clickreturnvalue()\" onMouseover=\"dropdownmenu(this, event, prices, '135px')\" onMouseout=\"delayhidemenu()\" class=\"linkDefault\">Prices</a> &nbsp;&nbsp;&nbsp;" );
	document.write( "										<a href='photos.html' class='linkDefault'>Photos</a> &nbsp;&nbsp;&nbsp;" );
	document.write( "										<a href='faq.html' class='linkDefault'>FAQ</a> &nbsp;&nbsp;&nbsp; " );
	document.write( "										<a href='contacts.html' class='linkDefault'>Contacts</a> &nbsp;&nbsp;&nbsp; " );
	
	document.write( "										<a href='reviews.html' class='linkDefault'>Reviews</a> &nbsp;&nbsp;&nbsp; " );	
	
	document.write( "										<a href='f_index.html' class='linkDefault'>Fran&ccedil;ais</a>" );	
	document.write( "									</td>" );
	document.write( "								</tr>" );
	document.write( "								<tr>" );
	document.write( "									<td width='686' height='1' class='pageBorder'></td>" );
	document.write( "								</tr>" );
	document.write( "							</table>" );
	document.write( "						</td>" );
	document.write( "					</tr>" );
	document.write( "				</table>" );
	document.write( "			</td>" );
	document.write( "		</tr>" );
	document.write( "		<!--- HEADER --->" );
	document.write( "		<tr>" );
	document.write( "			<td width='800'>" );
	document.write( "				<table cellSpacing='0' cellPadding='0' width='800' align='center' border='0'>" );
	document.write( "					<tr>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	document.write( "						<td width='127' valign='top' class='contentDescription'>" );
	document.write( "							<img src='images/descriptionBufferHeader.jpg' border='0' alt=''>" );
	document.write( "						</td>" );
	document.write( "						<td width='670' class='contentDescription'>" );
	document.write( "							<table cellSpacing='0' cellPadding='0' width='670' align='center' border='0' class='contentDescription'>" );
	document.write( "								<tr>" );
	document.write( "									<td width='670' class='header'>" );
	document.write( "<!--- PAGE TITLE --->					&nbsp;&nbsp;&nbsp;&nbsp;" + target );
	document.write( "									<td>" );
	document.write( "								</tr>" );
	document.write( "							</table>" );
	document.write( "						<td>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	document.write( "					</tr>" );
	document.write( "				</table>" );
	document.write( "			</td>" );
	document.write( "		</tr>" );
	document.write( "		<!--- SEPERATOR --->" );
	document.write( "		<tr><td width='800' height='1' class='pageBorder'><td></tr>" );
	document.write( "		<tr><td width='800' height='5' class='menu'><td></tr>" );
	document.write( "		<tr><td width='800' height='1' class='pageBorder'><td></tr>" );
	document.write( "		<tr>" );
	document.write( "			<td width='800'>" );
	document.write( "				<!--- CONTENT - MAIN TABLE - START --->" );
	document.write( "				<table cellSpacing='0' cellPadding='0' width='800' align='center' border='0'>" );
	document.write( "					<tr>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	
	
	if(background == 'GOING_GREEN')
	{
		document.write( "					<td width='798' class='tabs-going-green'>" );
		document.write( "						<br>" );
	}
	else
	{
		document.write( "					<td width='798' class='tabs'>" );
		document.write( "						<br>" );
	}
	
}


// function :: writeFooter()
// --------------------------------------------------------------------------------
function writeFooter()
{
	document.write( "							<br>" );
	document.write( "						<td>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	document.write( "					</tr>" );
	document.write( "				</table>" );
	document.write( "				<!--- CONTENT - MAIN TABLE - END --->" );
	document.write( "			</td>" );
	document.write( "		</tr>" );
	document.write( "		<!--- FOOTER --->" );
	document.write( "		<tr><td width='800' height='1' class='pageBorder'><td></tr>" );
	document.write( "		<tr><td width='800' height='5' class='menu'><td></tr>" );
	document.write( "		<tr><td width='800' height='1' class='pageBorder'><td></tr>" );
	document.write( "	</table>" );
	document.write( "	<!--- MAIN TABLE --- END --->" );
}	


// function :: writeHeader( target)
// --------------------------------------------------------------------------------
// target - Name of the page that matches to the menu 'if' statements.
// --------------------------------------------------------------------------------
function f_writeHeader( target, background )
{
	document.write( "	<!--- MAIN TABLE --- START --->" );
	document.write( "	<table cellSpacing='0' cellPadding='0' width='800' align='center' border='0'>" );
	document.write( "		<tr>" );
	document.write( "			<!--- HEADER - BANNER --->" );
	document.write( "			<td width='800'><img src='images/header-left.jpg' border='0'><a href='http://www.olhomes.ca/f_thinkingofgoinggreen.html'><img src='images/f_header-right.jpg' border='0'></a><td>" );
	document.write( "		</tr>" );
	document.write( "		<tr>" );
	document.write( "			<td width='800'>" );
	document.write( "				<!--- MENU --->" );
	document.write( "				<table cellSpacing='0' cellPadding='0' width='800' align='center' border='0'>" );
	document.write( "					<tr>" );
	document.write( "						<td width='114'><img src='images/menuBuffer.jpg' border='0'></td>" );
	document.write( "						<td width='686'>" );
	document.write( "							<table cellSpacing='0' cellPadding='0' width='686' align='center' border='0'>" );
	document.write( "								<tr>" );
	document.write( "									<td width='686' height='1' class='pageBorder'></td>" );
	document.write( "								</tr>" );
	document.write( "								<tr>" );
	document.write( "									<td width='686' height='26' class='menu'>" );
	document.write( "										&nbsp;" );
	document.write( "										<a href='f_index.html' class='linkDefault'>Accueil</a> &nbsp;&nbsp;&nbsp; " );
	document.write( "										<a href='f_floorPlans.html' class='linkDefault'>Modèles</a> &nbsp;&nbsp;&nbsp;" );
	document.write( "										<a href=\"f_index.html\" onClick=\"return clickreturnvalue()\" onMouseover=\"dropdownmenu(this, event, fpackages, '135px')\" onMouseout=\"delayhidemenu()\" class=\"linkDefault\">Listes De Matériaux</a> &nbsp;&nbsp;&nbsp;" );
	document.write( "										<a href=\"f_index.html\" onClick=\"return clickreturnvalue()\" onMouseover=\"dropdownmenu(this, event, fprices, '135px')\" onMouseout=\"delayhidemenu()\" class=\"linkDefault\">Prix</a> &nbsp;&nbsp;&nbsp;" );
	document.write( "										<a href='f_photos.html' class='linkDefault'>Photos</a> &nbsp;&nbsp;&nbsp;" );
	document.write( "										<a href='f_contacts.html' class='linkDefault'>Contacts</a> &nbsp;&nbsp;&nbsp; " );
	document.write( "										<a href='f_reviews.html' class='linkDefault'>Revoit</a> &nbsp;&nbsp;&nbsp; " );		
	document.write( "										<a href='index.html' class='linkDefault'>English</a>" );		
	document.write( "									</td>" );
	document.write( "								</tr>" );
	document.write( "								<tr>" );
	document.write( "									<td width='686' height='1' class='pageBorder'></td>" );
	document.write( "								</tr>" );
	document.write( "							</table>" );
	document.write( "						</td>" );
	document.write( "					</tr>" );
	document.write( "				</table>" );
	document.write( "			</td>" );
	document.write( "		</tr>" );
	document.write( "		<!--- HEADER --->" );
	document.write( "		<tr>" );
	document.write( "			<td width='800'>" );
	document.write( "				<table cellSpacing='0' cellPadding='0' width='800' align='center' border='0'>" );
	document.write( "					<tr>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	document.write( "						<td width='127' valign='top' class='contentDescription'>" );
	document.write( "							<img src='images/descriptionBufferHeader.jpg' border='0' alt=''>" );
	document.write( "						</td>" );
	document.write( "						<td width='670' class='contentDescription'>" );
	document.write( "							<table cellSpacing='0' cellPadding='0' width='670' align='center' border='0' class='contentDescription'>" );
	document.write( "								<tr>" );
	document.write( "									<td width='670' class='header'>" );
	document.write( "<!--- PAGE TITLE --->					&nbsp;&nbsp;&nbsp;&nbsp;" + target );
	document.write( "									<td>" );
	document.write( "								</tr>" );
	document.write( "							</table>" );
	document.write( "						<td>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	document.write( "					</tr>" );
	document.write( "				</table>" );
	document.write( "			</td>" );
	document.write( "		</tr>" );
	document.write( "		<!--- SEPERATOR --->" );
	document.write( "		<tr><td width='800' height='1' class='pageBorder'><td></tr>" );
	document.write( "		<tr><td width='800' height='5' class='menu'><td></tr>" );
	document.write( "		<tr><td width='800' height='1' class='pageBorder'><td></tr>" );
	document.write( "		<tr>" );
	document.write( "			<td width='800'>" );
	document.write( "				<!--- CONTENT - MAIN TABLE - START --->" );
	document.write( "				<table cellSpacing='0' cellPadding='0' width='800' align='center' border='0'>" );
	document.write( "					<tr>" );
	document.write( "						<td width='1' class='pageBorder'></td>" );
	
	if(background == 'GOING_GREEN')
	{
		document.write( "						<td width='798' class='tabs-going-green'>" );
		document.write( "							<br>" );
	}
	else
	{
		document.write( "						<td width='798' class='tabs'>" );
		document.write( "							<br>" );
	}
	
}





