//-----------------------------------------------------------------------------
// index.js
// Copyright © 1999-2006 by MacV Software.  All Rights Reserved.
// Description:		
// Author:			Vince McGowan
// Creation date:	5/19/1999 2:25:24 PM
//-----------------------------------------------------------------------------

// navigation folders, descriptions
var arHomePages = new Array (
	"index.htm",
	"biography.htm",
	"familysites.htm"
	);
var arHomeDesc = new Array (
	"Home Page",
	"Martin J. McGowan Sr. Biography",
	"Other McGowan Sites"
	);

//---------------------------------------------------------------------------------------
function buildSubNavigation(active)
{
	buildMainNavigation("home");

	// home page navigation
	var sidePanel = document.getElementById("sidepanel");
	
	var img = document.createElement("img");
	img.src = "images/martinis.jpg";
	img.className = "thumb";
	img.width = 180;
	img.height = 100;
	sidePanel.appendChild(img);

	var H3 = document.createElement("h3");
	H3.className = "first";
	H3.innerHTML = "Home Selections";
	sidePanel.appendChild(H3);

	UL = document.createElement("ul");
	UL.className = "sub";

	for (var i = 0; i < arHomePages.length; i++)
	{
		var isActive = (active == arHomePages[i].substr(0,active.length));
		LI = document.createElement("li");
		if (isActive)
			LI.className = "active";
		AR = document.createElement("a");
		if (isActive)
			AR.id = "activelink";
		AR.href = arHomePages[i];
		AR.innerHTML = arHomeDesc[i];
		LI.appendChild(AR);
		UL.appendChild(LI);
	}
	sidePanel.appendChild(UL);
	try {
		var activelink = document.getElementById("activelink");
		activelink.focus();		
	} catch (e) { }
}