<?php
/**
 * login_view.php - Login view file
 *
 * @author $Author: wichai $
 * @version $Id: login_view.php,v 1.4 2011/05/16 07:59:06 wichai Exp $
 * @copyright Copyright (c) 2009, Tiller Software Co., Ltd.
*/
echo form_open($form_link);
$tmp_msg = $this->session->flashdata('SURVEY_LOGIN_MSG');
if ( !empty($tmp_msg) )
	$msg = $tmp_msg;
$noticemsg = $this->config->item('cms_login_message');
?>
<center>
<div style="height:20px"></div>
<h2><?php echo $site_title;?></h2>
<div style="height:20px"></div>
<table width="10%" cellspacing="15" style="border:2px solid #660000;">
  <tr>
    <td width="25%" align="right" nowrap="nowrap" style="font-size:13px;font-weight:bold"><?php echo lang('login_username');?>: </td>
    <td width="75%" align="left" nowrap="nowrap">
    	<input type="text" name="username" size="16" maxlength="45" value="<?php echo $username?>" style="font-size:13px" /></td>
  </tr>
  <tr>
    <td align="right" nowrap="nowrap" style="font-size:13px;font-weight:bold"><?php echo lang('login_password');?>:</td>
    <td align="left" nowrap="nowrap"><input type="password" name="password" size="16" maxlength="65" style="font-size:13px" /></td>
  </tr>
  <tr>
    <td width="25%" align="right" nowrap="nowrap" style="font-size:13px;font-weight:bold"><?php echo lang('survey_survey_number');?>: </td>
    <td width="75%" align="left" nowrap="nowrap">
    	<input type="text" name="surveyid" size="10" maxlength="12" value="<?php echo $surveyid?>" style="font-size:13px" /></td>
  </tr>
  <tr>
    <td colspan="2" align="center"><input type="submit" value="<?php echo lang('login_submit')?>" <?php osa_btn();?>  /></td>
    </tr>
</table>
<?php
	if( !empty($noticemsg) ){
?>
	<div class="login_message"><?php echo $noticemsg ?></div>
<?php } ?>
</center>
<?php echo '</form>'; //Use echo to fool Eclipse IDE validation?>
<?php if ($msg) { ?>
<center><span style="color:red;"><b><?php echo $msg;?></b></span></center>
<?php } ?>

<?php if ($msg_mode) { ?>
<center><span class="login_message"><b><?php echo $msg_mode;?></b></span></center>
<?php } ?>

<div style="margin-bottom:150px;"></div>