<tr>
 <td colspan='2' align='left' class='bgpost2'>
 <script type="text/javascript" src="jscripts/ipb_poll.js"></script>
 <script type="text/javascript">
  var showfullonload     = parseInt("{$show_open}");
  var is_mod             = parseInt("{$is_mod}");
  
  // Questions
  var poll_questions     =
  {
{$poll_questions}
  };
  
  var poll_choices       = 
  {
{$poll_choices}
  };
  
  var poll_votes       = 
  {
{$poll_votes}
  };
  var poll_multi       = 
  {
{$poll_multi}
  };
  
  // Setting elements
  var max_poll_questions = parseInt("{$max_poll_questions}");
  var max_poll_choices   = parseInt("{$max_poll_choices}");
  
  // HTML elements
  var html_add_question     = "[<a href='#' title='{$this->ipsclass->lang['poll_tt_add_question']}' style='color:green;font-weight:bold' onclick='return poll_add_question()'>{$this->ipsclass->lang['poll_tt_add_question']}</a>]";
  var html_add_choice       = "<li>&nbsp;[<a href='#' title='{$this->ipsclass->lang['poll_tt_add_choice']}' style='color:green;font-weight:bold' onclick='return poll_add_choice("+'"'+'<%1>'+'"'+")'>{$this->ipsclass->lang['poll_tt_add_choice']}</a>]</li>";
  var html_question_box     = "<input type='text' id='question_<%1>' name='question[<%1>]' size='50' class='input' value='<%2>' /> [<a href='#' title='{$this->ipsclass->lang['poll_tt_remove_question']}' style='color:red;font-weight:bold' onclick='return poll_remove_question("+'"'+'<%1>'+'"'+")'>X</a>]<br /><input class='checkbox' type='checkbox' id='multi_<%1>' name='multi[<%1>]' value='1' <%3> /><span class='forumdesc'>{$this->ipsclass->lang['poll_multichoice']}</span>";
  var html_votes_box        = "&nbsp;<input type='text' id='votes_<%1>_<%2>' name='votes[<%1>_<%2>]' size='5' class='input' value='<%3>' />";
  var html_choice_box       = "<li><input type='text' id='choice_<%1>_<%2>' name='choice[<%1>_<%2>]' size='35' class='input' value='<%3>' /><%4> [<a href='#' title='{$this->ipsclass->lang['poll_tt_remove_choice']}' style='color:red;font-weight:bold' onclick='return poll_remove_choice("+'"'+'<%1>_<%2>'+'"'+")'>X</a>]</li>";
  var html_choice_wrap      = "<ol><%1></ol>";
  var html_question_wrap    = "<div><%1></div>";
  var html_stat_wrap        = "<br /><div><%1></div>";
  
  // Lang elements
  var js_lang_confirm    = "{$this->ipsclass->lang['poll_tt_confirm']}";
  var poll_stat_lang     = "{$this->ipsclass->lang['poll_tt_stat_lang']}";
 </script>
 <!--CLOSED DIV-->
 <div align='center' id='poll-box-closed' style='display:none' class='borderwrap'>
 <table cellpadding='0' cellspacing='0' width='100%' class='darkrow3'>
  <tr>
   <td align="right" valign='top' width='20%'>
	<strong>{$this->ipsclass->lang['poll_fs_options']}</strong>
   </td>
   <td valign="top" align='left'>
	<a href='#' onclick='show_poll_form(); return false;'>{$this->ipsclass->lang['poll_manage_link']}</a>
   </td>
  </tr>
 </table>
 </div>
 <!--/CLOSED DIV-->
 
 <!--OPEN DIV-->
 <div align='center' id='poll-box-open' style='display:none' class='borderwrap'>
 <table cellpadding='0' cellspacing='0' width='100%' class='darkrow3'>
  <tr>
   <td align="right" valign='top' width='20%'>
	<strong>{$this->ipsclass->lang['poll_fs_options']}</strong>
   </td>
   <td align='left' valign="top">
    <fieldset>
     <legend><strong>{$this->ipsclass->lang['poll_fs_title']}</strong></legend>
     <input type='text' size='40' class='input' name='poll_question' value='{$poll_question}' />
    </fieldset>
<if="$this->ipsclass->vars['ipb_poll_only']==1">
<fieldset>
     <legend><strong>{$this->ipsclass->lang['poll_only_title']}</strong></legend>
     <input class='checkbox' type='checkbox' name='poll_only' value='1' {$poll_only} /> <span class='forumdesc'>{$this->ipsclass->lang['poll_only_desc']}<span>
    </fieldset>
</if>
    <!-- MAIN POLL AREA -->
    <fieldset>
     <legend><strong>{$this->ipsclass->lang['poll_fs_content']}</strong></legend>
      <div id='poll-box-main'>
    
      </div>
    </fieldset>
    <!-- MAIN POLL AREA -->
    <br />
    <a href='#' onclick='close_poll_form(); return false;'>{$this->ipsclass->lang['poll_fs_close']}</a>
    <div id='poll-box-stat'></div>
   </td>
  </tr>
 </table>
 </div>
 <!--/OPEN DIV-->
 
 <!-- INIT DIVS -->
 <script type="text/javascript">
  poll_init_state();
 </script>
 <!--/ INIT DIVS -->
 </td>
</tr>