function outputTakeBar(pollnameu,prevq,pfx)
{
     document.write('<table border=0 width=100% cellspacing=0 cellpadding=0 BGCOLOR="#FFFFFF"><tr><td ALIGN="RIGHT">');
     if (prevq != "") {
          document.write('<b>[</b><A HREF="/polls/take/?pollname=');
          document.write(pollnameu);
          if (pfx != "") {
               document.write('&prefix=');
               document.write(pfx);
          }
          document.write('"><b>Start Over</b></A><b>]</b>');
          document.write('&nbsp;<b></b><A HREF="/polls/take/?pollname=');
          document.write(pollnameu);
          document.write('&qnumber=');
          document.write(prevq);
          if (pfx != "") {
               document.write('&prefix=');
               document.write(pfx);
          }
          document.write('"><b>&lt;&lt; Previous Question</b></A><b></b>');
          if (getCookie("pollframe") == "0") {
               document.write('</td><td align=right><b>[</b><A HREF="/polls/?useframes=0"><b>Menu</b></A><b>]</b>');
          }
     }
     else {
          document.write('<b>[Start Over] &lt;&lt; Previous Question</b>');
          if (getCookie("pollframe") == "0") {
               document.write('</td><td align=right><b>[</b><A HREF="/polls/?useframes=0"><b>Menu</b></A><b>]</b>');
          }
     }
     document.write('</td></tr></table>');
}

function outputLookBar(pollnameu,prevq,nextq,pfx,uid)
{
     document.write('<table cellspacing=0 cellpadding=0 BGCOLOR="#FFFFFF"><tr><td ALIGN="RIGHT">');
     if (prevq != "") {
          document.write('<b>[</b><A HREF="/polls/take/?pollname=');
          document.write(pollnameu);
          document.write('&lookup=');
          document.write(uid);
          if (pfx != "") {
               document.write('&prefix=');
               document.write(pfx);
          }
          document.write('"><b>Start Over</b></A><b>]</b>');
          document.write('&nbsp;<A HREF="/polls/take/?pollname=');
          document.write(pollnameu);
          document.write('&lookup=');
          document.write(uid);
          document.write('&qnumber=');
          document.write(nextq);
          if (pfx != "") {
               document.write('&prefix=');
               document.write(pfx);
          }
          document.write('&nbsp;<A HREF="/polls/take/?pollname=');
          document.write(pollnameu);
          document.write('&lookup=');
          document.write(uid);
          document.write('&qnumber=');
          document.write(prevq);
          if (pfx != "") {
               document.write('&prefix=');
               document.write(pfx);
          }
          document.write('"><b>&lt;&lt; Previous Question</b></A>');
          if (getCookie("pollframe") == "0") {
               document.write('</td><td align=right><b>[</b><A HREF="/polls/?useframes=0"><b>Menu</b></A><b>]</b>');
          }
     }
     else {
          document.write('<b>[Start Over] &lt;&lt;Previous Question</b>');
          document.write('&nbsp;<b>[</b><A HREF="/polls/take/?pollname=');
          document.write(pollnameu);
          document.write('&lookup=');
          document.write(uid);
          document.write('&qnumber=');
          document.write(nextq);
          if (pfx != "") {
               document.write('&prefix=');
               document.write(pfx);
          }
          if (getCookie("pollframe") == "0") {
               document.write('</td><td align=right><b>[</b><A HREF="/polls/?useframes=0"><b>Menu</b></A><b>]</b>');
          }
     }
     document.write('</td></tr></table>');
}

function outputQuestionBar(number)
{
     document.write('<table border=0 bgcolor="88FFFF" width=100% cellspacing=0 cellpadding=0 cellspacing=0><tr bgcolor="#B9D2EB"><td>');
     document.write('<FONT FACE="Arial" COLOR="#606060" SIZE="2"><B>Question #:');
     document.write(++number);
     document.write('</B></FONT></td></tr></table><BR>');
}

function outputButtons(pollname,prefix)
{
     document.write('<HR><TABLE WIDTH=100% border=0 cellwidth=2 cellspacing=2><tr><td><input type="hidden" name="pollname" value="');
     document.write(pollname);
     document.write('">');
     document.write('<input type="hidden" name="prefix" value="');
     document.write(prefix);
     document.write('">');
     document.write('&nbsp;<input type="Submit" name="Submit" value="Submit">');
     document.write('&nbsp;<input type="Reset" name="Reset" value="Reset"></TD></TR></TABLE></FORM>');
}

function initOutput()
{
	 var inframe=(getCookie("pollframe") == "1");
     if (!inframe) {
          writeHeader();
     }
     document.write('<TABLE bgcolor="FFFFFF" bordercolor="808080" BORDER=0 width=100% cellwidth=0 cellspacing=0 cellpadding=0>');
     document.write('<TR><TD BGCOLOR="#F0F0F0">');
}

