document.write('<style type="text/css">');
document.write('');

document.write('#ddimagetabs{');
document.write('}');
document.write('');
document.write('#ddimagetabs a{');
document.write('display: block;');
document.write('text-decoration: none;');
document.write('font: bold 12px Arial; /*tab font */');
document.write('color: black; /*font color */');
document.write('width: 83px; /*width of tab image */');
document.write('height: 20px; /*height of tab image */');
document.write('float: left;');
document.write('display: inline;');
document.write('margin-left: 0px; /*spacing between tabs */');
document.write('padding-top:4px; /*vertical offset of tab text from top of tab*/');
document.write('background-image:url(images/bluetab.gif); /*URL to tab image */');
document.write('background-repeat: no-repeat;');
document.write('text-align: left;');
document.write('}');
document.write('');
document.write('#ddimagetabs a:hover, #ddimagetabs a.current{');
document.write('background-image:url(images/bluetabover.gif); /*URL to tab image onmouseover */');
document.write('color: white;');
document.write('}');
document.write('');
document.write('#tabcontentcontainer{');
document.write('width:480px; /*width of 2nd level content*/');
document.write('height:16px; /*height of 2nd level content. Set to largests content height to avoid jittering.*/');
document.write('}');
document.write('');
document.write('.tabcontent{');
document.write('display:none;');
document.write('}');
document.write('');
document.write('.rss {') ;
document.write('	border:1px solid;') ;
document.write('	border-color:#FC9 #630 #330 #F96;') ;
document.write('	padding:0 2px;') ;
document.write('	font:bold 10px verdana,sans-serif;') ;
document.write('	color:#FFF;') ;
document.write('	background:#F60;') ;
document.write('	text-decoration:none;') ;
document.write('	margin:0;') ;
document.write('	margin-right:10px;') ;
document.write('}') ;
document.write('a {color: black;text-decoration:underline;font:bold;}');
document.write('.flow {');
document.write('  float: left;');
document.write('  clear: left;');
document.write('  margin: 0px 1.25em 0px 0px;');
document.write('}');
document.write('.topichead {');
document.write('  background-image: url(images/gradient.jpg);');
document.write('  background-repeat: repeat-y;');
document.write('}');

document.write('#topicimage {');
document.write('  background-image: url(images/white.gif);');
document.write('  background-repeat: no-repeat;');
document.write('  background-attachment: scroll;');
document.write('  margin: 0px;');
document.write('  padding: 0px;');
document.write('  border: 0px;');
document.write('}');

document.write('</style>');
document.write('');

/***********************************************
 * DD Tab Menu II script- © Dynamic Drive DHTML code library (www.dynamicdrive.com)')
 * This notice MUST stay intact for legal use')
 * Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code')
 ***********************************************/
var initialtab = [1, "sc1"]

var turntosingle = 0  //0 for no (default), 1 for yes

//Disable hyperlinks in 1st level tab images?
var disabletablinks = 0  //0 for no (default), 1 for yes

////////Stop editting////////////////

var previoustab = ""

if (turntosingle == 1)
  ;

function expandcontent(cid, aobject)
{
  if (disabletablinks == 1)
  {
    aobject.onclick = new Function("return false") ;
  }
  if (document.getElementById && turntosingle == 0)
  {
    highlighttab(aobject);
    if (previoustab != "")
    {
      document.getElementById(previoustab).style.display = "none";
    }
    document.getElementById(cid).style.display = "block";
    previoustab = cid;
  }
}

function highlighttab(aobject)
{
  if (typeof tabobjlinks == "undefined")
    collectddimagetabs();
  for (i = 0; i < tabobjlinks.length; i++)
  {
    tabobjlinks[i].className = "";
  }
  aobject.className = "current";
}

function collectddimagetabs()
{
  var tabobj = document.getElementById("ddimagetabs");
  tabobjlinks = tabobj.getElementsByTagName("A");
}

function do_onload()
{
  collectddimagetabs();
  expandcontent(initialtab[1], tabobjlinks[initialtab[0] - 1]);
}

if (window.addEventListener)
{
  window.addEventListener("load", do_onload, false)
}
else if (window.attachEvent)
{
  window.attachEvent("onload", do_onload)
}
else if (document.getElementById)
{
  window.onload = do_onload
}

function insubtopic (imagename, iconhover)
{
    document.images[imagename.name].src = iconhover;
}
function outsubtopic (imagename, iconnohover)
{
    document.images[imagename.name].src = iconnohover;
}
var imageprefix = "i" ;
var imagecounter = 1 ;

function makeTopicLink (oneliner, url, icontyp)
{
    var imageid = imageprefix + imagecounter ; imagecounter = imagecounter + 1 ;
    var linkicon = "" ;
    var linkiconhover = "" ;
    var fontsize = 12 ;
    var targetpage = "" ;
    var fonthilight = "0xbb0000" ;

    if (icontyp == "inverse")
	{
	    linkiconhover = "images/subtopicchooser.jpg" ;
	    linkicon = "images/subtopicchooserhover.jpg" ;
	    fontsize = 12 ;
	}
    else if (icontyp == "sound")
	{
	    linkiconhover = "images/subtopicsoundhover.gif" ;
	    linkicon = "images/subtopicsound.gif" ;
	    fontsize = 12 ;
	}
    else if (icontyp == "download")
	{
	    linkiconhover = "images/subtopicdownloadhover.gif" ;
	    linkicon = "images/subtopicdownload.gif" ;
	    fontsize = 12 ;
	}
    else if (icontyp == "externallink")
	{
	    targetpage = "_blank" ;
	    linkiconhover = "images/linkchooserhover.jpg" ;
	    linkicon = "images/linkchooser.jpg" ;
	    fonthilight = "0x00bb00" ;
	    fontsize = 9 ;
	}
    else
	{
	    linkiconhover = "images/subtopicchooserhover.jpg" ;
	    linkicon = "images/subtopicchooser.jpg" ;
	    fontsize = 12 ;
	}

    if (oneliner != "")
	{
	    document.write ('    ' + '<td><a target="' + targetpage + '" href="' + url + '">' + '<img name="' + imageid + '" style="border:0px;" onmouseover="insubtopic(' + imageid + ',\'' + linkiconhover + '\')" onmouseout="outsubtopic(' + imageid + ',\'' + linkicon + '\')"  src="' + linkicon + '">' + '</a></td><td valign="center" style="font:bold ' + fontsize + 'px arial;"><a target="' + targetpage + '" href="' + url + '" onmouseover="this.style.color=' + fonthilight + ';insubtopic(' + imageid + ',\'' + linkiconhover + '\')" onmouseout="this.style.color=0x000000;outsubtopic(' + imageid + ',\'' + linkicon + '\')">' + oneliner + '</a></td>') ;
	}
else
    {
	document.write ('<td><img height="23" src="images/noop.gif"></td>') ;
    }
}

function opensogwin (imagetoshow, showimageinpopup)
{
	if (! showimageinpopup)
		return false ;

	w = window.open (imagetoshow, "foo", "directories=no,location=no,menubar=no,resizeable=no,scrollbars=no,status=no,toolbar=no,width=420,height=420") ;
	w.focus() ;

	return false ;
}

function  topic (topicwidth, head, title, teaser,
		 oneliner1, url1, icontype1,
		 oneliner2, url2, icontype2,
		 oneliner3, url3, icontype3,
		 image, iwidth, iheight, showimageinpopup)
{
    document.write ('<img src="images/noop.gif" height="5">') ;

    document.write ('<div style="position:relative;width:' + topicwidth + 'px;">') ;
    document.write ('<table border="0" style="background-image:url(images/topicbackground.jpg);background-color:white;border:0px black solid;border-bottom:0px black solid;border-right:1px black solid;border-left:1px lightgrey solid;height:50px;">') ;

    document.write ('<tr>') ;
    document.write ('<td valign="top" style="height:26px;">') ;
    document.write ('<div class="topichead" style="position:relative;border:0px black solid;border-bottom:1px black solid;border-right:1px black solid;left:0px;width:100%;height:24px;font:bold 13px arial;color:grey;padding-left:0px;padding-top:4px;text-align:left;vertical-align:middle;">') ;
    document.write ('<span style="position:relative;left:22px;top:0px;">') ;
    document.write (head) ;
    document.write ('</span>') ;
    document.write ('<img style="position:absolute;left:2px;top:4px;" src="images/bulletleft.gif">') ;
    document.write ('<img style="position:absolute;right:2px;top:4px;" src="images/bulletright.gif">') ;
    document.write ('</div>') ;
    document.write ('</td>') ;
    document.write ('</tr>') ;
    
    if (title != "")
	{
	    document.write ('<tr>') ;
    
	    document.write ('<td>') ;
	    document.write ('<div style="left:5px;width:100%;font:bold 14px arial;color:black;">') ;
	    document.write (title) ;
	    document.write ('</div>') ;
	    document.write ('</td>') ;
	    
	    document.write ('</tr>') ;
	}

    document.write ('<tr>') ;
    document.write ('<td>') ;

    document.write ('<div id="topicimage"  style="border:0px black solid;background-image: url(images/' + image + ');left:0px;width:' + topicwidth + 'px;min-height:' + iheight + 'px;font:12px arial">') ;

    if (image != "" && showimageinpopup)
    {
            var magx = parseInt(iwidth) - 3 ;
            var magy = parseInt(iheight) - 12 ;

	    document.write ('<div id="mag" onmouseover="this.style.border=\'1px red solid;\';" onmouseout="this.style.border=\'0px black solid;\';"  style="border:0px black solid;z-index:99;background-image: url(images/mag.gif);position:relative;top:' + magy + 'px;left:' + magx + 'px;width:20px;height:21px;"   onClick="opensogwin(\'animations/' + image + '\',' + showimageinpopup + ')"  ></div>') ;

    }
    document.write ('<div class="flow" style="position:relative;top:-20px;width:' + iwidth + 'px; height:' + iheight + 'px;"></div>') ;

    if (image != "")
    {
 	    document.write ('<div style="position:relative;top:-20px;">') ;
	    document.write (teaser) ;
	    document.write ('</div>') ;
    }
    else
    {
    	    document.write (teaser) ;
    }

    document.write ('</div>') ;
    document.write ('</td>') ;
    document.write ('</tr>') ;

    document.write ('<tr>') ;
    document.write ('<td>') ;

//    document.write ('<img style="position:absolute;left:0px;bottom:2px;border-right:1px solid black;width:100%;" height="10" src="images/rolle.gif">') ;
	
    if (oneliner1 != "" ||  oneliner2 != "" ||  oneliner3 != "" )
    {
	document.write ('<table border="0"><tr>');

	makeTopicLink (oneliner1, url1, icontype1);
	document.write ('</tr>');

	document.write ('<tr>');
	makeTopicLink (oneliner2, url2, icontype2);
	document.write ('</tr>');
	
	document.write ('<tr>');
	makeTopicLink (oneliner3, url3, icontype3);
	
	document.write ('</tr></table>');
    }

    document.write ('</td>') ;
    document.write ('</tr>') ;

    
    document.write ('</table>') ;
    document.write ('<div>') ;
}

function foreignlinks (head, titlearray, flinksarray)
{
    var topicwidth = 135 ;

    document.write ('<div style="position:relative;width:' + topicwidth + 'px;">') ;

    document.write ('<img src="images/noop.gif" height="5">') ;
    document.write ('<table border="0" style="background-image:url(images/topicbackground.jpg);background-color:white;border:0px black solid;border-bottom:0px black solid;border-right:2px black solid;height:200px;">') ;

    document.write ('<tr>') ;
    document.write ('<td valign="top" style="height:26px;">') ;
    document.write ('<div class="topichead" style="position:relative;border:0px black solid;border-bottom:1px black solid;border-right:1px black solid;left:0px;width:100%;height:24px;font:bold 13px arial;color:grey;padding-left:0px;padding-top:4px;text-align:left;vertical-align:middle;">') ;
    document.write ('<span style="position:relative;left:22px;top:0px;">') ;
    document.write (head) ;
    document.write ('</span>') ;
    document.write ('<img style="position:absolute;left:2px;top:4px;" src="images/bulletleft.gif">') ;
    document.write ('<img style="position:absolute;right:2px;top:4px;" src="images/bulletright.gif">') ;
    document.write ('</div>') ;
    document.write ('</td>') ;
    document.write ('</tr>') ;

    for (j=0; j<(titlearray.length); j++)
	{
	    var title = titlearray[j] ;
	    var flinks = flinksarray[j] ;

	    document.write ('<tr>') ;

	    document.write ('<td valign="top" style="height:18px;">') ;
	    document.write ('<div style="left:5px;width:' + topicwidth + 'px;font:bold 12px arial;color:black;">') ;
	    document.write (title) ;
	    document.write ('</div>') ;
	    document.write ('</td>') ;
	    document.write ('</tr>') ;
	    
	    // start the links
	    
	    document.write ('<tr>') ;
	    document.write ('<td valign="top">') ;
	    
	    document.write ('<table border="0">');
	    
	    for (i=0; i<(flinks.length); i+=2)
		{
		    document.write ('<tr>');
		    makeTopicLink (flinks[i], flinks[i+1], "externallink");
		    document.write ('</tr>');
		}
	    
	    document.write ('</table>');
	    
	    document.write ('</td>') ;
	    document.write ('</tr>') ;

	    // end the links
	}

    document.write ('</div>') ;
    document.write ('</table>') ;
}

function pagetitle (title)
{
    var titlewidth = 750 ;

    document.write ('<div class="topichead" style="position:relative;background-image:url(images/logo.jpg);border:0px black solid;left:0px;width:' + titlewidth + 'px;height:118px;font:bold 13px arial;color:darkred;padding:0px;text-align:left;vertical-align:middle;">') ;
    document.write ('<div style="height:5px;"><img src="images/noop.gif"></div>') ;
    document.write ('<div style="font:bold 40px arial;color:lightgrey;padding-left:10px;">' + title + '</div>') ;
    document.write ('<div style="height:20px;"><img src="images/noop.gif"></div>') ;
    pagemenu() ;
    document.write ('<img style="position:absolute;left:2px;top:4px;" src="images/bulletleft.gif">') ;
    document.write ('<img style="position:absolute;right:2px;top:4px;" src="images/bulletright.gif">') ;
    document.write ('</div>') ;
}

function externallinks ()
{
    var extHeadLines = new Array (
			  "Learning Go",
			  "Go associations",
			  "Other Go software",
			  "Go libraries",
			  "Go file formats"
	  ) ;

    var links1 = new Array (
			   "Go problems", "http://www.goproblems.com/",
			   "Teaching ladder", "http://gtl.xmp.net/",
			   "Senseis library","http://senseis.xmp.net/",
			   "Books","http://www.gobooks.info/",
			   "",""
			   ) ;
    var links2 = new Array (
			    "European Go","http://www.european-go.org/",
			    "American Go","http://www.usgo.org",
			    "Nihon Ki-in","http://www.nihonkiin.or.jp/index-e.htm",
			    "Deutscher Go-Bund","http://www.dgob.de/",
			    "Fédération Française","http://ffg.jeudego.org/",
			    "",""
			    ) ;
    var links3 = new Array (
			    "HandTalk","http://www.yutopian.com/go/",
			    "Jago", "http://www.rene-grothmann.de/jago/",
			    "GnuGo", "http://www.gnu.org/software/gnugo/",
			    "Many Faces Of Go","http://www.smart-games.com/manyfaces.html",
			    "Go Tools","http://www.qmw.ac.uk/~ugah006/gotools/",
			    "",""
			   ) ;
    var links4 = new Array (
			    "Arno's Fuseki Library", "http://xmp.net/arno/fuseki.html",
			    "Kogo's Joseki Dictionary", "http://waterfire.us/joseki.htm",
			    "",""
			   ) ;
    var links5 = new Array (
			    "SGF file format", "http://www.red-bean.com/sgf/",
			    "Jago XML", "http://www.rene-grothmann.de/jago/Documentation/xml.html"
			   ) ;


   var extLinks = new Array (links1, links2, links3, links4, links5) ;

   foreignlinks ("Other places", extHeadLines, extLinks) ;
}

function pagemenu ()
{
document.write('<div id="ddimagetabs">');
document.write('<DIV id="tabcontentcontainer">');
document.write('<font face="arial" size="1" >');
document.write('<div id="sc1" class="tabcontent">');
document.write('&nbsp;&nbsp;Return to the frontpage of Shades of Go');
document.write('</div>');
document.write('<div id="sc2" class="tabcontent">');
document.write('&nbsp;&nbsp;Watch how Shades of Go looks in action');
document.write('</div>');
document.write('<div id="sc3" class="tabcontent">');
document.write('&nbsp;&nbsp;Download your free version of Shades of Go now');
document.write('</div>');
document.write('<div id="sc4" class="tabcontent">');
document.write('&nbsp;&nbsp;Getting started: A comprehensive introduction into the game of Go <strong>for beginners</strong>');
document.write('</div>');
document.write('<div id="sc5" class="tabcontent">');
document.write('&nbsp;&nbsp;Some rules of thumb beginners might find true after having played Go for a while</strong>');
document.write('</div>');
document.write('<div id="sc6" class="tabcontent">');
document.write('&nbsp;&nbsp;The making of: some technical background information');
document.write('</div>');
document.write('<div id="sc7" class="tabcontent">');
document.write('&nbsp;&nbsp;You can help: Make Shades of Go available in your local language');
document.write('</div>');
document.write('<div id="sc8" class="tabcontent">');
document.write('&nbsp;&nbsp;&nbsp;You have questions using Shades of Go? Maybe you find an answer here...');
document.write('</div>');
document.write('<div id="sc9" class="tabcontent">');
document.write('&nbsp;&nbsp;The legal stuff...');
document.write('</div>');
document.write('</font>');
document.write('</div>'); // tabcontentcontainer
document.write('<font face="arial">');
document.write('<a href="about.htm" onMouseover="expandcontent(\'sc1\', this)">&nbsp;&nbsp;Home</a>');
document.write('<a href="screenshots.htm" onMouseover="expandcontent(\'sc2\', this)">&nbsp;&nbsp;Screenshots</a>');
document.write('<a href="download.htm" onMouseover="expandcontent(\'sc3\', this)">&nbsp;&nbsp;Download</a>');
document.write('<a href="basicrules.htm" onMouseover="expandcontent(\'sc4\', this)">&nbsp;&nbsp; Rules</a>');
document.write('<a href="basicstrategy.htm" onMouseover="expandcontent(\'sc5\', this)">&nbsp;&nbsp;&nbsp;Basics</a>');
document.write('<a href="techdetails.htm" onMouseover="expandcontent(\'sc6\', this)">&nbsp;&nbsp;Making of</a>');
document.write('<a href="action.htm" onMouseover="expandcontent(\'sc7\', this)">&nbsp;Call for action</a>');
document.write('<a href="faq.htm" onMouseover="expandcontent(\'sc8\', this)">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Help</a>');
document.write('<a href="impressum.htm" onMouseover="expandcontent(\'sc9\', this)">&nbsp;&nbsp;Impressum</a>');
document.write('</font>');
document.write('</DIV>');
}

document.write('<HEAD>');
document.write('	<META HTTP-EQUIV="Content-Type" CONTENT="text/html;CHARSET=iso-8859-1">');
document.write('	<link rel="SHORTCUT ICON" href="images/sog.ico" type="image/ico">') ;
document.write('	<META HTTP-EQUIV="Content-Type" CONTENT="text/html;CHARSET=iso-8859-1">');
document.write('	<META NAME="Author" CONTENT="Stefan Freitag">');
document.write('        <META NAME="keywords" CONTENT="shades of go, Shades of Go, baduk, weiqi, go, problems, tesuji, fuseki, joseki, life and death, solve, solving, .NET, .net, framework, tokamak, goban, go-ban, ">');
document.write('        <META NAME="description" CONTENT="Play go across the Internet, locally, or against your computer.">');
document.write('        <META http-equiv="Page-Enter" content="blendTrans(Duration=0.4)">');
document.write('        <META http-equiv="Page-Exit" content="blendTrans(Duration=0.4)">');
document.write('	<LINK rel="alternate" type="application/rss+xml" title="RSS 2.0" href="" />');

document.write('	<TITLE>Shades of Go - Play Go across the Internet or against the computer</TITLE>');
document.write('	<script type="text/javascript" src="tjpzoom.js"></script>') ;

document.write('</HEAD>');

var lastqID = "";
function showanswer (answer, questionID)
{
    document.getElementById (42).innerHTML = '<div style="color: green;font-weight: bold;"><br><strong>Answer:</strong><br></div>' + answer;

    document.getElementById ('q'+questionID).style.fontWeight = "bold";
    document.getElementById ('q'+questionID).style.color = "red";

    if (lastqID != "")
	{
	    document.getElementById ('q'+lastqID).style.fontWeight = "normal";
	    document.getElementById ('q'+lastqID).style.color = "black";
	}
    lastqID = questionID ;
}

function faqlist (topicwidth, faqlist, image, iwidth, iheight)
{
    document.write ('<img src="images/noop.gif" height="5">') ;

    document.write ('<div style="position:relative;width:' + topicwidth + 'px;">') ;
    document.write ('<table border="0" style="background-image:url(images/topicbackground.jpg);background-color:white;border:0px black solid;border-bottom:0px black solid;border-right:1px black solid;border-left:1px lightgrey solid;height:450px;">') ;

    document.write ('<tr>') ;
    document.write ('<td valign="top" style="height:26px;">') ;
    document.write ('<div class="topichead" style="position:relative;border:0px black solid;border-bottom:1px black solid;border-right:1px black solid;left:0px;width:100%;height:24px;font:bold 13px arial;color:grey;padding-left:0px;padding-top:4px;text-align:left;vertical-align:middle;">') ;
    document.write ('<span style="position:relative;left:22px;top:0px;">') ;
    document.write ("Frequently asked questions") ;
    document.write ('</span>') ;
    document.write ('<img style="position:absolute;left:2px;top:4px;" src="images/bulletleft.gif">') ;
    document.write ('<img style="position:absolute;right:2px;top:4px;" src="images/bulletright.gif">') ;
    document.write ('</div>') ;
    document.write ('</td>') ;
    document.write ('</tr>') ;
    
    document.write ('<tr>') ;

    document.write ('<td valign="top">') ;
    document.write ('<div style="left:5px;width:100%;font:bold 14px arial;color:black;">') ;
    document.write ("Move the mouse over any question to see the answer") ;
    document.write ('</div>') ;
    document.write ('</td>') ;

    document.write ('</tr>') ;

    document.write ('<tr>') ;

    document.write ('<td valign="top">') ;
    document.write ('<div id="topicimage" style="border:0px black solid;background-image: url(' + image + ');left:0px;width:' + topicwidth + 'px;min-height:' + iheight + 'px;font:12px arial">') ;
    document.write ('<div class="flow" style="width:' + iwidth + 'px; height:' + iheight + 'px;"> </div>') ;

    var qno = 0 ;
    document.write ('<div style="color: green;font-weight: bold;"><strong>Questions:</strong><br></div>') ;
    while (faqlist.length > 1)
	{
	    q = faqlist.shift () ;
	    a = faqlist.shift () ;

	    qno = qno+1 ;

	    document.write ('<div id="' + 'q' + qno + '" style="width:100%" onmouseover="showanswer(\'' + a + '\', ' + qno + ')">' + qno + '. ' + q + '</div>') ;
	}

    document.write ('<br><div id="42" style="padding-left:8px;position:relative;top:4px;height:300px;border-top:1px black dashed;font:plain 14px arial;color:black;">') ;
    document.write ('<br>Move the mouse over any question in the list above to find the answer here.') ;
    document.write ('</div>') ;

    document.write ('</div>') ;
    document.write ('</td>') ;

    document.write ('</tr>') ;

    document.write ('<tr>') ;
    document.write ('<td>') ;

//    document.write ('<img style="position:absolute;left:0px;bottom:2px;border-right:1px solid black;width:100%;" height="10" src="images/rolle.gif">') ;
	
    document.write ('</td>') ;
    document.write ('</tr>') ;

    
    document.write ('</table>') ;
    document.write ('</div>') ;
}
