<?php include VIEW_DIR.'mobile/common/menu/poll.tpl'; ?>

<form method="post" action="<?php e($this->_vars['action']['url']); ?>"><?php HTML::requires(); ?>
<?php if ($this->_vars['action']['complete'] || $this->_vars['action']['deleted']): ?>
<table border="0" width="<?php Theme::exec()->mainWidth(); ?>">
	<tr><td align="center" bgcolor="<?php Theme::exec()->bgTitleColor(); ?>"><img src="<?php e(BASE_URL); ?>resource/img/icons/chart_pie.gif" width="16" height="16" alt="&gt;">&nbsp;<?php e($this->_vars['poll']['poll']); ?></td></tr>
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>" align="center">
		<img src="<?php e(BASE_URL); ?>resource/img/icons/resultset_previous.gif" width="16" height="16" alt="&gt;">
		<img src="<?php e(BASE_URL); ?>resource/img/icons/resultset_previous.gif" width="16" height="16" alt="&gt;">&nbsp;<a href="<?php e(RKT_Controller::getHttpReferer(2)); ?>"><?php _e('Go back'); ?></a>&nbsp;
		<img src="<?php e(BASE_URL); ?>resource/img/icons/resultset_previous.gif" width="16" height="16" alt="&gt;">
		<img src="<?php e(BASE_URL); ?>resource/img/icons/resultset_previous.gif" width="16" height="16" alt="&gt;"><br>
		<?php e($this->_vars['action']['complete']? _('Answered'):_('Deleted')); ?><br><br><?php loadPlugin::callFunc('hitsuji_banner', POSITION_MOBILE); ?><br>
	<br></td></tr>
</table>
<?php elseif ($this->_vars['action']['confirm'] || $this->_vars['action']['delete']): ?>
<table border="0" width="<?php Theme::exec()->mainWidth(); ?>">
	<tr><td align="center" bgcolor="<?php Theme::exec()->bgTitleColor(); ?>"><img src="<?php e(BASE_URL); ?>resource/img/icons/chart_pie.gif" width="16" height="16" alt="&gt;">&nbsp;<?php e($this->_vars['poll']['poll']); ?></td></tr>
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>">
		<?php loadPlugin::callFunc('hitsuji_profile', $this->_vars['base']['account']['id'], 'vSmall,nickname'); ?><br>
	</td></tr>
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>">
		<font color="<?php Theme::exec()->columnColor(); ?>"><?php _e('Answer'); ?>:&nbsp;</font><?php e($this->_vars['answers'][$this->_vars['sum_answer']['answer']]); ?>
	<br></td></tr>
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>" align="center">
		<input type="submit" name="manip" value="<?php e($this->_vars['action']['confirm']? _('Submit'):_('Delete')); ?>">
		<input name="back" type="submit" value="<?php _e('Go back'); ?>">
	<br></td></tr>
</table>
<?php else: ?>
<table border="0" width="<?php Theme::exec()->mainWidth(); ?>">
	<tr><td align="center" bgcolor="<?php Theme::exec()->bgTitleColor(); ?>"><img src="<?php e(BASE_URL); ?>resource/img/icons/chart_pie.gif" width="16" height="16" alt="&gt;">&nbsp;<?php e($this->_vars['poll']['poll']); ?></td></tr>
</table>
	<?php HTML::htmlBody($this->_vars['poll']['comment']); ?><br>
<table border="0" width="<?php Theme::exec()->mainWidth(); ?>">
	<tr><td bgcolor="<?php Theme::exec()->bgColumnColor(); ?>"><?php _e('Answer'); ?>:<br></td></tr>
	<tr><td>
		<?php if (!empty($this->_vars['alert']['answer'])): ?><font color="<?php Theme::exec()->alertColor(); ?>"><?php _e('Please select.'); ?></font><br><?php endif; ?>
		<?php HTML::radio('answer', $this->_vars['answers'], $this->_vars['sum_answer']['answer'], '<br>'); ?>
	<br></td></tr>
	<tr><td bgcolor="<?php Theme::exec()->bgColor(); ?>" align="center"><input type="submit" name="confirm" value="<?php _e('Confirm'); ?>"><br></td></tr>
</table>
<?php endif; ?>
</form>
