function ReportError(Message,URLString,LineString)
{
	window.status = "JSErr: " + Message + " (Line " + LineString+ ") " + 
				navigator.appName + " " + navigator.appVersion + " " + URLString;
	alert("JSErr: " + Message + " (Line " + LineString+ ") " + navigator.appName + " " + navigator.appVersion + " " + URLString);
	return true;
}
window.onerror = ReportError;

function Cookie(Document, Name, Hours, Path, Domain, Secure)
{
	this.$Document = Document
	this.$Name = Name
	this.$Expiration = null;
	if (Hours) this.$Expiration = new Date((new Date()).getTime() + Hours*3600000);
	this.$Path = null;
	if (Path) this.$Path = Path;
	this.$Domain = null;
	if (Domain) this.$Domain = Domain;
	this.$Secure = false;
	if (Secure) this.$Secure = true;
}

function _CookieStore()
{
	var CookieValue = "";
	var CookieString;
	var Variable;
	for (Variable in this)
	{
		if ((Variable.charAt(0) == '$') || ((typeof this[Variable]) == 'function')) continue;
		if (CookieValue != "") CookieValue += '&';
		CookieValue += Variable + ':' + escape(this[Variable]);
	}
	CookieString = this.$Name + '=' + CookieValue;
	if (this.$Expiration) CookieString += '; expires=' + this.$Expiration.toGMTString();
	if (this.$Path) CookieString += '; path=' + this.$Path;
	if (this.$Domain) CookieString += '; domain=' + this.$Domain;
	if (this.$Secure) CookieString += '; secure';
	this.$Document.cookie = CookieString;
}

function _CookieLoad()
{
	var AllCookies = this.$Document.cookie;
	if (AllCookies == "") return false;

	var Start = AllCookies.indexOf(this.$Name + "=");
	if (Start == -1) return false

	Start += this.$Name.length + 1;
	var End = AllCookies.indexOf(';', Start);
	if (End == -1) End = AllCookies.length;
	var CookieString = AllCookies.substring(Start, End);

	var VariableArray = CookieString.split('&');
	for (var i=0; i<VariableArray.length; i++) VariableArray[i] = VariableArray[i].split(':');
	for (var i=0; i<VariableArray.length; i++) this[VariableArray[i][0]] = unescape(VariableArray[i][1]);
	return true;
}

function _CookieText()
{
	var AllCookies = this.$Document.cookie;
	if (AllCookies == "") return false;

	var Start = AllCookies.indexOf(this.$Name + "=");
	if (Start == -1) return false

	Start += this.$Name.length + 1;
	var End = AllCookies.indexOf(';', Start);
	if (End == -1) End = AllCookies.length;
	var CookieString = AllCookies.substring(Start, End);

	var Text = '\n';
	var VariableArray = CookieString.split('&');
	for (var i=0; i<VariableArray.length; i++) VariableArray[i] = VariableArray[i].split(':');
	for (var i=0; i<VariableArray.length; i++) Text += unescape(VariableArray[i][1]) + '\n';
	return Text;
}

function _CookieRemove()
{
	var CookieString;
	CookieString = this.$Name + '=';
	if (this.$Path) CookieString += '; path=' + this.$Path;
	if (this.$Domain) CookieString += '; domain=' + this.$Domain;
	CookieString += '; expires=Fri, 02-Jan-1970 00:00:00 GMT';
	this.$Document.cookie = CookieString;
}

new Cookie();
Cookie.prototype.Store = _CookieStore;
Cookie.prototype.Load = _CookieLoad;
Cookie.prototype.Text =_CookieText;
Cookie.prototype.Remove = _CookieRemove;

function SetFormSelect(Selection, InText)
{
	for (var i=0; i<Selection.length; i++)
	{
		if (InText == Selection.options[i].value)
		{
			Selection.selectedIndex = i;
		}
	}
}

function GetFormSelect(Selection)
{
	return Selection.options[Selection.selectedIndex].value;
}

function Encode(it)
{
	var ot;ot = "";al = "abcdefghijklmnopqrstuvwxyz";li = 13;for (j=0; j<it.length; j++){le = it.substring(j,j+1);lc = le.toLowerCase();ix = al.indexOf(lc);if (ix != -1){ix = (ix + li) % 26;nl = al.substring(ix,ix+1);li = al.indexOf(lc);if (lc != le){nl = nl.toUpperCase();}ot += nl;}else{ot += le;}}return ot;
}

function Decode(it)
{
	var ot;ot = "";al = "abcdefghijklmnopqrstuvwxyz";li = 13;for (j=0; j<it.length; j++){le = it.substring(j,j+1);lc = le.toLowerCase();ix = al.indexOf(lc);if (ix != -1){ix = (ix - li + 26) % 26;nl = al.substring(ix,ix+1);li = al.indexOf(nl);if (lc != le){nl = nl.toUpperCase();}ot += nl;}else{ot += le;}}return ot;
}

function StripText(InText)
{
	var OutText;
	OutText = "";
	for (i=0; i<InText.length; i++)
	{
		Alphabet = "abcdefghijklmnopqrstuvwxyz0123456789-";
		LowerCaseLetter = InText.substring(i,i+1).toLowerCase();
		Index = Alphabet.indexOf(LowerCaseLetter);
		if (Index != -1)
		{
			OutText += LowerCaseLetter;
		}
	}
	return OutText;
}

function UpdateCookie(TheCookie, Puzzle, InText, Solved)
{
	if ((TheCookie+""=="") || (TheCookie+"" == "undefined"))
	{
		return;
	}
	d = new Date();
	i = d.getUTCFullYear();
	ShortDateTime = i.toString()
	ShortDateTime = ShortDateTime.substring(2,4);
	i = d.getUTCMonth();
	ShortDateTime = i.toString() + ShortDateTime;
	if (i < 10) ShortDateTime = "0" + ShortDateTime;
	i = d.getUTCDate();
	ShortDateTime = i.toString() + ShortDateTime;
	if (i < 10) ShortDateTime = "0" + ShortDateTime;
	i = d.getUTCMinutes();
	ShortDateTime = i.toString() + ShortDateTime;
	if (i < 10) ShortDateTime = "0" + ShortDateTime;
	if (i == 0) ShortDateTime = "0" + ShortDateTime;
	i = d.getUTCHours();
	ShortDateTime = i.toString() + ShortDateTime;
	if (i < 10) ShortDateTime = "0" + ShortDateTime;
	if (i == 0) ShortDateTime = "0" + ShortDateTime;
	DateString = ShortDateTime;

	if ((TheCookie[Puzzle+"FSD"]+"" == "") || (TheCookie[Puzzle+"FSD"]+"" == "undefined")) TheCookie[Puzzle+"FSD"] = "undefined";
	if ((TheCookie[Puzzle+"AC"]+"" == "") || (TheCookie[Puzzle+"AC"]+"" == "undefined")) TheCookie[Puzzle+"AC"] = 0;
	if ((TheCookie[Puzzle+"FD"]+"" == "") || (TheCookie[Puzzle+"FD"]+"" == "undefined")) TheCookie[Puzzle+"FD"] = "undefined";
	if ((TheCookie[Puzzle+"D"]+"" == "") || (TheCookie[Puzzle+"D"]+"" == "undefined")) TheCookie[Puzzle+"D"] = 2;

	if (InText == "")
	{
		if ((TheCookie[Puzzle+"FSD"]+"" == "") || (TheCookie[Puzzle+"FSD"]+"" == "undefined")) TheCookie[Puzzle+"FSD"] = DateString;
		TheCookie.Store();
		return;
	}
	TheCookie[Puzzle+"AC"]++;
	if (Solved)
	{
		TheCookie[Puzzle+"D"] = 3;
		TheCookie[Puzzle+"FD"] = DateString;
	}
	TheCookie.Store();
}

function CheckAnswer(InText, AnswerArray, TheCookie, Puzzle)
{
	Solved = false;
	NewLocation = "../Sorry.htm";
	EncodedInText = StripText(InText);
	var ListArray = AnswerArray[0].split(',');
	for (var i=0; i<ListArray.length; i++)
	{
		if (EncodedInText.indexOf(StripText(Decode(ListArray[i]))) != -1)
		{
			Solved = true;
		}
	}
	if (Solved)
	{
		Index = location.pathname.indexOf(".", location.pathname.indexOf(".")+1);
		NewLocation = location.pathname.substring(0, Index+1) + Decode(ListArray[0]) + ".htm";
	}
	else
	{
		k = 1;
		while (AnswerArray[k] != "")
		{
			var ListArray = AnswerArray[k].split(',');
			for (var i=0; i<ListArray.length; i++)
			{
				if (EncodedInText.indexOf(StripText(Decode(ListArray[i]))) != -1)
				{
					NewLocation = "../Close.htm?" + escape(Decode(AnswerArray[k+1]));
				}
			}
			k += 2;
		}
	}
	UpdateCookie(TheCookie, Puzzle, InText, Solved);
	location.href = NewLocation;
}

function CheckExactAnswer(InText, AnswerArray, TheCookie, Puzzle)
{
	Solved = false;
	NewLocation = "../Sorry.htm";
	EncodedInText = StripText(InText);
	var ListArray = AnswerArray[0].split(',');
	for (var i=0; i<ListArray.length; i++)
	{
		if (EncodedInText == StripText(Decode(ListArray[i])))
		{
			Solved = true;
		}
	}
	if (Solved)
	{
		Index = location.pathname.indexOf(".", location.pathname.indexOf(".")+1);
		NewLocation = location.pathname.substring(0, Index+1) + Decode(ListArray[0]) + ".htm";
	}
	else
	{
		k = 1;
		while (AnswerArray[k] != "")
		{
			var ListArray = AnswerArray[k].split(',');
			for (var i=0; i<ListArray.length; i++)
			{
				if (EncodedInText == StripText(Decode(ListArray[i])))
				{
					NewLocation = "../Close.htm?" + escape(Decode(AnswerArray[k+1]));
				}
			}
			k += 2;
		}
	}
	UpdateCookie(TheCookie, Puzzle, InText, Solved);
	location.href = NewLocation;
}

function CheckDynamicAnswer(InText, AnswerArray, TheCookie, Puzzle)
{
	Solved = false;
	NewLocation = "../Sorry.htm";
	EncodedInText = StripText(InText);
	var ListArray = AnswerArray[0].split(',');
	for (var i=0; i<ListArray.length; i++)
	{
		if (EncodedInText == StripText(Decode(ListArray[i])))
		{
			Solved = true;
		}
	}
	if (Solved)
	{
		Index = location.pathname.indexOf(".", location.pathname.indexOf(".")+1);
		NewLocation = location.pathname.substring(0, Index+1) + Decode(ListArray[0]) + ".htm";
	}
	else
	{
		k = 1;
		while (AnswerArray[k] != "")
		{
			var ListArray = AnswerArray[k].split(',');
			for (var i=0; i<ListArray.length; i++)
			{
				if (EncodedInText == StripText(Decode(ListArray[i])))
				{
					NewLocation = "../Close.htm?" + escape(Decode(AnswerArray[k+1]));
				}
			}
			k += 2;
		}
	}
	UpdateCookie(TheCookie, Puzzle, InText, false);
	if (NewLocation != "../Sorry.htm")
	{
		location.href = NewLocation;
	}
}

function CheckExactNumberedChainedAnswer(InText, AnswerArray, TheCookie, Puzzle, Number, OutOf)
{
	Solved = false;
	NewLocation = "../Sorry.htm";
	EncodedInText = StripText(InText);
	var ListArray = AnswerArray[0].split(',');
	for (var i=0; i<ListArray.length; i++)
	{
		if (EncodedInText == StripText(Decode(ListArray[i])))
		{
			Solved = true;
		}
	}
	if (Solved)
	{
		NumberString = (Number + 1).toString();
		if (NumberString.length == 1){NumberString = "0" + NumberString;}
		FirstIndex = location.pathname.indexOf(".");
		SecondIndex = location.pathname.indexOf(".", FirstIndex+1);
		NewHead = location.pathname.substring(0, FirstIndex - 2) + NumberString;
		NewLocation = NewHead + location.pathname.substring(FirstIndex, SecondIndex+1) + Decode(ListArray[0]) + ".htm";
		if (Number != OutOf)
		{
			Solved = false;
		}
	}
	else
	{
		k = 1;
		while (AnswerArray[k] != "")
		{
			var ListArray = AnswerArray[k].split(',');
			for (var i=0; i<ListArray.length; i++)
			{
				if (EncodedInText == StripText(Decode(ListArray[i])))
				{
					NewLocation = "../Close.htm?" + escape(Decode(AnswerArray[k+1]));
				}
			}
			k += 2;
		}
	}
	UpdateCookie(TheCookie, Puzzle, InText, Solved);
	location.href = NewLocation;
}

function CheckExactChainedAnswer(InText, AnswerArray, TheCookie, Puzzle, Number, OutOf)
{
	Solved = false;
	NewLocation = "../Sorry.htm";
	EncodedInText = StripText(InText);
	var ListArray = AnswerArray[0].split(',');
	for (var i=0; i<ListArray.length; i++)
	{
		if (EncodedInText == StripText(Decode(ListArray[i])))
		{
			Solved = true;
		}
	}
	if (Solved)
	{
		Index = location.pathname.indexOf(".", location.pathname.indexOf(".")+1);
		NewLocation = location.pathname.substring(0, Index+1) + Decode(ListArray[0]) + ".htm";
		if (Number != OutOf)
		{
			Solved = false;
		}
	}
	else
	{
		k = 1;
		while (AnswerArray[k] != "")
		{
			var ListArray = AnswerArray[k].split(',');
			for (var i=0; i<ListArray.length; i++)
			{
				if (EncodedInText == StripText(Decode(ListArray[i])))
				{
					NewLocation = "../Close.htm?" + escape(Decode(AnswerArray[k+1]));
				}
			}
			k += 2;
		}
	}
	UpdateCookie(TheCookie, Puzzle, InText, Solved);
	location.href = NewLocation;
}

function CheckChainedAnswer(InText, AnswerArray, TheCookie, Puzzle, Number, OutOf)
{
	Solved = false;
	NewLocation = "../Sorry.htm";
	EncodedInText = StripText(InText);
	if (EncodedInText.indexOf(StripText(Decode(AnswerArray[0]))) != -1)
	{
		Index = location.pathname.indexOf(".", location.pathname.indexOf(".")+1);
		NewLocation = location.pathname.substring(0, Index+1) + Decode(AnswerArray[0]) + ".htm";
		
		if (Number == OutOf)
		{
			Solved = true;
		}
	}
	else
	{
		k = 1;
		while (AnswerArray[k] != "")
		{
			if (EncodedInText.indexOf(StripText(Decode(AnswerArray[k]))) != -1)
			{
				NewLocation = "../Close.htm?" + escape(Decode(AnswerArray[k+1]));
			}
			k += 2;
		}
	}
	UpdateCookie(TheCookie, Puzzle, InText, Solved);
	location.href = NewLocation;
}

function WriteHeader(HeadingString, Path, ALink)
{
    document.writeln('<TABLE ALIGN="center" CELLPADDING="0" CELLSPACING="0" WIDTH="540" BORDER="0">')
      document.writeln('<TR>')
        document.writeln('<TD ALIGN="center" WIDTH="540">')
          document.writeln('<P>')
			if ((ALink + "") != "" && (ALink + "") != "undefined") document.writeln('<A HREF="' + ALink + '">')
             document.writeln('<IMG ALT="" BORDER="0" WIDTH="540" HEIGHT="80" SRC="' + Path + 'Images/TheStoneUnturned.gif">')
			if ((ALink + "") != "" && (ALink + "") != "undefined") document.writeln('</A>')
          document.writeln('</P>')
	if (HeadingString != "")
	{
		document.writeln('<H4>')
			document.writeln(HeadingString)
		document.writeln('</H4>')

	}
        document.writeln('</TD>')
      document.writeln('</TR>')
    document.writeln('</TABLE>')
      document.writeln('<HR SIZE="1" WIDTH="650" NOSHADE>')
}

function WriteFooter(CopyrightName, CopyrightEmail, Path, ImagesPath)
{
	if (typeof(ImagesPath) == "undefined")
	{
		ImagesPath = Path;
	}
   ImageArray = new Array(18)
   {
   ImageArray[1] = new Image(40,40)
   ImageArray[1].src = ImagesPath + "Images/HomeButton.gif"
   }
   {
   ImageArray[2] = new Image(40,40)
   ImageArray[2].src = ImagesPath + "Images/HomeButton2.gif"
   }
   {
   ImageArray[3] = new Image(40,40)
   ImageArray[3].src = ImagesPath + "Images/TheStonesButton.gif"
   }
   {
   ImageArray[4] = new Image(40,40)
   ImageArray[4].src = ImagesPath + "Images/TheStonesButton2.gif"
   }
   {
   ImageArray[5] = new Image(40,40)
   ImageArray[5].src = ImagesPath + "Images/AboutButton.gif"
   }
   {
   ImageArray[6] = new Image(40,40)
   ImageArray[6].src = ImagesPath + "Images/AboutButton2.gif"
   }
   {
   ImageArray[7] = new Image(40,40)
   ImageArray[7].src = ImagesPath + "Images/StatisticsButton.gif"
   }
   {
   ImageArray[8] = new Image(40,40)
   ImageArray[8].src = ImagesPath + "Images/StatisticsButton2.gif"
   }
   {
   ImageArray[15] = new Image(40,40)
   ImageArray[15].src = ImagesPath + "Images/TheWikiButton.gif"
   }
   {
   ImageArray[16] = new Image(40,40)
   ImageArray[16].src = ImagesPath + "Images/TheWikiButton2.gif"
   }
   {
   ImageArray[17] = new Image(40,40)
   ImageArray[17].src = ImagesPath + "Images/OldNewsButton.gif"
   }
   {
   ImageArray[18] = new Image(40,40)
   ImageArray[18].src = ImagesPath + "Images/OldNewsButton2.gif"
   }
    document.writeln('<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" WIDTH="540" ALIGN="center">')
      document.writeln('<TR>')
        document.writeln('<TD WIDTH="540" ALIGN="center">')
      document.writeln('<HR SIZE="1" WIDTH="650" NOSHADE>')
        document.writeln('</TD>')
      document.writeln('</TR>')
    document.writeln('</TABLE>')
    document.writeln('<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" WIDTH="540" ALIGN="center">')

		document.writeln('<TR>')
        document.writeln('<TD WIDTH="17%" ALIGN="center">')
          document.write('<H5><A HREF="' + Path + 'Home.htm"')
		    	document.write(' ONMOUSEOVER="Home.src=ImageArray[2].src; self.status=\'Home\' ; return true" ')
          document.write(' ONMOUSEOUT="Home.src=ImageArray[1].src; self.status=\'\' ; return true"')
    			document.write('>')
    			document.write('<IMG SRC="' + ImagesPath + 'Images/HomeButton.gif" NAME="Home" ALT="Return Home" WIDTH="40" HEIGHT="40" BORDER="0" ALIGN="middle"></A>')
    			document.write('<BR>Home</H5>')
        document.writeln('</TD>')

        document.writeln('<TD WIDTH="17%" ALIGN="center">')
          document.write('<H5><A HREF="' + Path + 'TheStones.htm"')
		    	document.write(' ONMOUSEOVER="TheStones.src=ImageArray[4].src; self.status=\'The Stones\' ; return true" ')
          document.write(' ONMOUSEOUT="TheStones.src=ImageArray[3].src; self.status=\'\' ; return true"')
    			document.write('>')
    			document.write('<IMG SRC="' + ImagesPath + 'Images/TheStonesButton.gif" NAME="TheStones" ALT="The Stones" WIDTH="40" HEIGHT="40" BORDER="0" ALIGN="middle"></A>')
    			document.write('<BR>The Stones</H5>')
        document.writeln('</TD>')

        document.writeln('<TD WIDTH="16%" ALIGN="center">')
          document.write('<H5><A HREF="http://www.thestoneunturned.com/cgi-bin/thestonewiki.pl"')
		    	document.write(' ONMOUSEOVER="TheWiki.src=ImageArray[16].src; self.status=\'The Wiki\' ; return true" ')
          document.write(' ONMOUSEOUT="TheWiki.src=ImageArray[15].src; self.status=\'\' ; return true"')
    			document.write('>')
    			document.write('<IMG SRC="' + ImagesPath + 'Images/TheWikiButton.gif" NAME="TheWiki" ALT="The Wiki" WIDTH="40" HEIGHT="40" BORDER="0" ALIGN="middle"></A>')
    			document.write('<BR>The Wiki</H5>')
        document.writeln('</TD>')

        document.writeln('<TD WIDTH="16%" ALIGN="center">')
          document.write('<H5><A HREF="' + Path + 'About.htm"')
		    	document.write(' ONMOUSEOVER="About.src=ImageArray[6].src; self.status=\'About\' ; return true" ')
          document.write(' ONMOUSEOUT="About.src=ImageArray[5].src; self.status=\'\' ; return true"')
    			document.write('>')
    			document.write('<IMG SRC="' + ImagesPath + 'Images/AboutButton.gif" NAME="About" ALT="About" WIDTH="40" HEIGHT="40" BORDER="0" ALIGN="middle"></A>')
    			document.write('<BR>About</H5>')
        document.writeln('</TD>')

        document.writeln('<TD WIDTH="17%" ALIGN="center">')
          document.write('<H5><A HREF="' + Path + 'OldNews.htm"')
		    	document.write(' ONMOUSEOVER="OldNews.src=ImageArray[18].src; self.status=\'Old News\' ; return true" ')
          document.write(' ONMOUSEOUT="OldNews.src=ImageArray[17].src; self.status=\'\' ; return true"')
    			document.write('>')
    			document.write('<IMG SRC="' + ImagesPath + 'Images/OldNewsButton.gif" NAME="OldNews" ALT="Old News" WIDTH="40" HEIGHT="40" BORDER="0" ALIGN="middle"></A>')
    			document.write('<BR>Old News</H5>')
        document.writeln('</TD>')

        document.writeln('<TD WIDTH="17%" ALIGN="center">')
          document.write('<H5><A HREF="' + Path + 'Statistics.htm"')
		    	document.write(' ONMOUSEOVER="Statistics.src=ImageArray[8].src; self.status=\'Statistics\' ; return true" ')
          document.write(' ONMOUSEOUT="Statistics.src=ImageArray[7].src; self.status=\'\' ; return true"')
    			document.write('>')
    			document.write('<IMG SRC="' + ImagesPath + 'Images/StatisticsButton.gif" NAME="Statistics" ALT="Statistics" WIDTH="40" HEIGHT="40" BORDER="0" ALIGN="middle"></A>')
     			document.write('<BR>Statistics</H5>')
       document.writeln('</TD>')
		document.writeln('</TR>')

	document.writeln('</TABLE>')	  
//	  document.writeln('<BR>')
    document.writeln('<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" WIDTH="540" ALIGN="center">')
      document.writeln('<TR ALIGN="center">')
        document.writeln('<TD>')
          document.writeln('<H6>')
//            document.writeln('<A CLASS="h6" HREF="http://www.vestige.org/ring/">Ring of Stone</A>&nbsp;&nbsp;&nbsp;&nbsp;<A CLASS="h6" HREF="http://nav.webring.org/cgi-bin/navcgi?ring=fishsauce;id=14;prev"><<</a>&nbsp;&nbsp;&nbsp;&nbsp;<A CLASS="h6" HREF="http://nav.webring.org/cgi-bin/navcgi?ring=fishsauce;list">?</a>&nbsp;&nbsp;&nbsp;&nbsp;<A CLASS="h6" HREF="http://nav.webring.org/cgi-bin/navcgi?ring=fishsauce;id=14;next">>></a>')
//            document.writeln('<BR>')
            document.writeln('<A CLASS="h6" HREF="http://www.thestone.net">The Stone</A> and associated materials are the property of <A CLASS="h6" HREF="http://www.abject.com">Abject Modernity</A>')
		if ((CopyrightName != "") && (CopyrightEmail == ""))
		{
			document.writeln('<BR>')
			document.writeln('This puzzle and materials are &copy; 2000,2001,2002 '+ CopyrightName)
		}
		if ((CopyrightName != "") && (CopyrightEmail != ""))
		{
			document.writeln('<BR>')
			document.writeln('This puzzle and materials are &copy; 2000,2001,2002 <A CLASS="h6" HREF="mailto:' + CopyrightEmail + '">'+ CopyrightName + '</A>')
		}
            document.writeln('<BR>')
            document.writeln('All other materials are &copy; 2000,2001,2002 <A CLASS="h6" HREF="mailto:timeistheanswer@email.com;atom1ant@bellsouth.net">Mark Butler & Atom_Gold</A>')
          document.writeln('</H6>')
        document.writeln('</TD>')
      document.writeln('</TR>')
   document.writeln('</TABLE>')
}
function WhiteBlackGif(WhiteNumber, BreakAt, TotalNumber)
{

	for (var Number=0; Number<TotalNumber; Number++)
	{
		if (Number == BreakAt) document.writeln('<BR>');
		if (Number < WhiteNumber)
		{
			document.writeln('<IMG BORDER="0" WIDTH="13" HEIGHT="13" SRC="Images/White.gif" ALT=" ">');
		}
		else
		{
			document.writeln('<IMG BORDER="0" WIDTH="13" HEIGHT="13" SRC="Images/Black.gif" ALT=" ">');
		}
	}
}
