//Button text
var text = new Array();
text[1]  = "Home";
text[2]  = "Web Development";
text[3]  = "Windows Scripting Host";
text[4]  = "Feedback";

//target URLs
var link = new Array();
link[1] = "index.html";
link[2] = "webdev.html";
link[3] = "wsh.html";
link[4] = "feedback.html";

//section names
var sect = new Array();
sect[1] = "home";
sect[2] = "webdev";
sect[3] = "wsh";
sect[4] = "feedback";

//target frames
var target = new Array();
target[1] = "_top";
target[2] = "body";
target[3] = "body";
target[4] = "new";

//link images
var image = new Array();
image[1] = "images/home.gif";
image[2] = "images/webdev.gif";
image[3] = "images/wsh.gif";
image[4] = "images/feedback.gif";

//mouse over images
var oimage = new Array();
oimage[1] = "images/yhome.gif";
oimage[2] = "images/ywebdev.gif";
oimage[3] = "images/ywsh.gif";
oimage[4] = "images/yfeedback.gif";

var numcols = 4;

function write_button(num, frames) {
	var code =""

        if (frames == "1")
	{
	    code += "<tr>"
	}	
	code += "<td><a href=\"" + link[num] + "\""

	if (frames == "1")
	{
		code += " target=" + target[num]
	}
	code += "><img src=\"" + image[num] + "\" alt=\"" + text[num] + "\"border=0\""
		+ " onMouseover=\"this.src='"
		+ oimage[num] + "';\" onMouseout=\"this.src='" + image[num] + "';\"></a></td>"
	
        if (frames == "1")
	{
	    code += "</tr>"
	}	
	self.document.write(code)

}

function show_header(page) {
	// don't show header if we are using a navigation frame
	if ( parent.document.frameform.frames.value == "n")
	{
	    self.document.write('<table border=0 cellpadding=3 cellspacing=0><tr>');
	    
	    for (var i=1; i<text.length; i++)
	    {
		// don't show link if we are in that section
		if ( page == sect[i] )
		{
		    self.document.write("<td><img src=\"" + image[i] + "\" alt=\"" + text[i] + "\"></td>");
		}
		else
		{
		    write_button(i, 0);
		}
	    }
	    self.document.write('</tr></table>');
	}
}

function show_navbar() {
	    self.document.write('<table border=0 cellpadding=10 cellspacing=0>');
	    
	    for (var i=1; i<text.length; i++)
	    {
		write_button(i, 1);
	    }
	    self.document.write('</table>');
}

function do_footer( updated )
{
    self.document.write('<hr><b CLASS="clsFooter">This page was last revised: ' + updated + '</a></b>');
}

//"main" - add a hidden field in case the calling page is the top (parent) frame for the non-frames case.
//	   This should get overridden by a similar field in the parent frame if frames are being used.
	self.document.write('<form name="frameform"><INPUT TYPE=HIDDEN NAME="frames" VALUE="n"></form>');
	
