
/*
Expanding Sidebar Inserter :
inserts a navigation sidebar into a page without the need to update every page when new links are added (typically, the code below should go in a css box or table cell that parallels that of the main content box).

in <head>:
   <script src='[path]/sidebar.js' type='text/javascript'></script>

in <body>:
   <div id='sidebar'>
      <script language='JavaScript' type='text/javascript'>
         <!--
            if (self.GetSidebar) document.write(GetSidebar(true/false));
         // -->
      </script>
   </div>
*/

if (navigator.appVersion.charAt(0) > 4 || navigator.userAgent.indexOf('MSIE') != -1)
{
   top.document.title = self.document.title;
}

function MenuToggle(menuTopic)
{
   var itemNode = menuTopic.nextSibling;

   if("block" != itemNode.style.display)
   {
      itemNode.style.display="block"
   }
   else
   {
      itemNode.style.display="none"
   }
}


function GetSidebar(isExpand)
{
   var headerText = " class='open'";
   var subText = "";
   if ('true' == isExpand)
   {
      headerText = " class='expand' onclick='MenuToggle(this)'";
      subText = " class='subMenu'";
   }

   navLinks = "<h1" + headerText + ">SVG</h1><div" + subText + ">";

   navLinks += "<h2><a href='differentstrokes.html' title='SVG Stroke Proposal'>Diff'rent Strokes</a></h2><p>A proposal to allow variable line widths in SVG, to help artists and decrease file sizes all in one swell foop.</p>";

   navLinks += "<h2><a href='svgaccessibility.html' title='SVG Accessibility'>SVG Accessibility</a></h2><p>An attempt to bring Web graphics into the 21st century.</p>";

   navLinks += "<h2><a href='inlinesvg.html' title='Inline SVG'>Inline SVG</a></h2><p>A how-to on using inline SVG using version 3 of Adobe's SVG Viewer.</p>";

   navLinks += "<h2><a href='svgcomic.html' title='Drawing SVG Comics'>SVG-Whiz!</a></h2><p>A tutorial series on drawing online comics in SVG.</p>";

   navLinks += "<h2><a href='workshop.html' title='Workshop'>Workshop</a></h2><p>A few SVG projects I'm involved in, and some tools I use.</p>";

   navLinks += "</div>";

   navLinks += "<h1" + headerText + ">Toys</h1><div" + subText + ">";

   navLinks += "<h2><a href='storytime.html' title='Story Time'>Story Time</a></h2><p>I go through books at a pretty steady pace, and when I really need to, I write a bit as well.</p>";

   navLinks += "<h2><a href='superhero.html' title='Superhero DIY Kit'>Superhero DIY Kit</a></h2><p>Everything you need to know to fight for Truth, Justice, and AmWay.</p>";

   navLinks += "<h2><a href='gaming/index.html' title='Nerdtopia'>Gaming</a></h2><p>My dirty little secret... a grown man plays Dungeons&Dragons. (&#8220;I kill it with my axe!&#8221;)</p>";

   navLinks += "</div>";

   navLinks += "<h1" + headerText + ">Links</h1><div" + subText + ">";

   navLinks += "<h2><a href='techlinks.html' title='Tech Links'>Tech</a></h2><p>A few noteworthy technical sites, for things like SVG, XML, CSS/HTML, and C#.</p>";

   navLinks += "<h2><a href='comiclinks.html' title='Comics Links'>Comics</a></h2><p>A selection of some of my favorite online comic-books.</p>";

   navLinks += "</div>";

   navLinks += "<h1" + headerText + ">About</h1><div" + subText + ">";

   navLinks += "<h2><a class='help' href='controlpanel.html' title='Control Panel'>Control Panel</a></h2><p class='help'>How to use or misuse this site.</p>";

   navLinks += "<h2><a href='sitemap.html' title='Sitemap'>Sitemap</a></h2><p>Simply a text-based list of links on this site. Soon to be a graphical representation of this site, though.</p>";

   navLinks += "<h2><a href='resume.html' title='Resume'>Resume</a></h2><p>A brief history of time for money.</p>";

   navLinks += "<h2><a href='me.html' title='Me'>Me</a></h2><p>...And now for a word from our sponsor.</p>";

   navLinks += "<h2><a href='index.html' title='Blahg'>News</a></h2><p>Trivial maintenance minutiae.</p>";

   navLinks +=  "</div>";

   return navLinks;
}


