/***************************************************
**                                                **
** Title: Pop-Up JavaScript Library               **
** Date: August 23, 2000                          **
** Author:  Kofi Garbrah                          **
** Purpose: Causes a new window to be opened      **
**          containing an html document. This new **
**          window will NOT contain the toolbars  **
**          or navigation bars of an internet     **
**          browser but it CAN be scrolled or     **
**          resized.                              **
**                                                **
****************************************************/

// Global Variable
// This variable represents the Pop-Up window
var PopUp;

// This function compensates for the change in
// how we numbered the images; we went from a
// Two digit system to an alphabetical sytem.
// Rather than re-code over 1000 webpages,
// I decided to change this one file instead.
//
//  -Kofi Garbrah
//
function correct_old_numbering(doc) 
{
	var newdoc;
	var number = doc.substring(1,doc.indexOf("_"));
	var name = doc.substring(doc.indexOf("_"),doc.length);
	if ((doc.substring(0,1) == "i") && (number.length > 0))
		doc = "i" + name;
	return doc;

}

// Generates a Pop-Up window that has
// no directories and no menu or toobars.  
// This window can be resized, however.
//
// - Kofi Garbrah
//
function pop_up(html_document) 
{
	var PopUpString =
         "toolbar=no,location=no,directories=no,status=no," +
         "menubar=no,scrollbars=yes,resizeable=yes," +
          "width=450,height=480";
	
	var new_html_document = correct_old_numbering(html_document);
	PopUp = window.open(new_html_document, "HeritageTrail", PopUpString);

}

function pop2(URL,Title,WindowOptions)
{
	PopUp2=window.open(URL,Title,WindowOptions);
	PopUp2.focus();
}
