<?php /* Smarty version 2.6.18, created on 2008-04-22 01:28:50
         compiled from book.html */ ?>
<?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'wordwrap', 'book.html', 36, false),)), $this); ?>

<!--以下为中间主要布局部分:center -->
<?php echo '
<script language=\'javascript\'>
function chk()
{
var d = new Date();
document.getElementById(\'rand\').src="captcha.php?t="+d.toTimeString()
}
</script>
'; ?>

<div id="center">
  <div id="centerby">
   <div class="tl">
   <div class="tr">
      <!-- 留言本布局 -->
      <div id="book_a">
	  		<div id="nr"></div>
			<?php if ($this->_tpl_vars['error']): ?><div id="error"> 错误：<?php echo $this->_tpl_vars['error']; ?>
 </div><?php endif; ?>
			<?php if ($this->_tpl_vars['result']): ?>
			<?php unset($this->_sections['row']);
$this->_sections['row']['name'] = 'row';
$this->_sections['row']['loop'] = is_array($_loop=$this->_tpl_vars['result']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['row']['show'] = true;
$this->_sections['row']['max'] = $this->_sections['row']['loop'];
$this->_sections['row']['step'] = 1;
$this->_sections['row']['start'] = $this->_sections['row']['step'] > 0 ? 0 : $this->_sections['row']['loop']-1;
if ($this->_sections['row']['show']) {
    $this->_sections['row']['total'] = $this->_sections['row']['loop'];
    if ($this->_sections['row']['total'] == 0)
        $this->_sections['row']['show'] = false;
} else
    $this->_sections['row']['total'] = 0;
if ($this->_sections['row']['show']):

            for ($this->_sections['row']['index'] = $this->_sections['row']['start'], $this->_sections['row']['iteration'] = 1;
                 $this->_sections['row']['iteration'] <= $this->_sections['row']['total'];
                 $this->_sections['row']['index'] += $this->_sections['row']['step'], $this->_sections['row']['iteration']++):
$this->_sections['row']['rownum'] = $this->_sections['row']['iteration'];
$this->_sections['row']['index_prev'] = $this->_sections['row']['index'] - $this->_sections['row']['step'];
$this->_sections['row']['index_next'] = $this->_sections['row']['index'] + $this->_sections['row']['step'];
$this->_sections['row']['first']      = ($this->_sections['row']['iteration'] == 1);
$this->_sections['row']['last']       = ($this->_sections['row']['iteration'] == $this->_sections['row']['total']);
?>
			<div id="book_tab">
			<table width="480" border="0" cellspacing="0" cellpadding="0" id="table">
  			<tr>
    		<th colspan="2" scope="col" id="thead"><?php echo $this->_tpl_vars['result'][$this->_sections['row']['index']]['l_id']; ?>
  标题：<?php echo $this->_tpl_vars['result'][$this->_sections['row']['index']]['l_title']; ?>
</th>
  			</tr>
  			<tr>
    		<td class="ttl">留言者：<?php echo $this->_tpl_vars['result'][$this->_sections['row']['index']]['l_name']; ?>
</td>
    		<td class="ttl">留言时间：<?php echo $this->_tpl_vars['result'][$this->_sections['row']['index']]['l_time']; ?>
</td>
  			</tr>
  			<tr>
   			<td class="ttl">留言者IP：<?php echo $this->_tpl_vars['result'][$this->_sections['row']['index']]['l_ip']; ?>
</td>
    		<td class="ttl">留言者Email:<?php echo $this->_tpl_vars['result'][$this->_sections['row']['index']]['l_mail']; ?>
</td>
  			</tr>
  			<tr>
    		<td colspan="2" class="tbl">留言内容：<br /><?php echo ((is_array($_tmp=$this->_tpl_vars['result'][$this->_sections['row']['index']]['l_lynr'])) ? $this->_run_mod_handler('wordwrap', true, $_tmp, 66, "<br />", true) : smarty_modifier_wordwrap($_tmp, 66, "<br />", true)); ?>
</td>
  			</tr>
  			<tr>
    		<td colspan="2" class="tbl"><?php if ($this->_tpl_vars['result'][$this->_sections['row']['index']]['hf_nr']): ?>管理员回复：<?php echo $this->_tpl_vars['result'][$this->_sections['row']['index']]['hf_nr']; ?>
<?php endif; ?></td>
  			</tr>
			</table>
			</div> <!-- book_tab -->
			<?php endfor; endif; ?>
			<div id="page"><span>共[<?php echo $this->_tpl_vars['pagenum']; ?>
]页</span>
			<?php unset($this->_sections['row']);
$this->_sections['row']['name'] = 'row';
$this->_sections['row']['loop'] = is_array($_loop=$this->_tpl_vars['pages']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['row']['show'] = true;
$this->_sections['row']['max'] = $this->_sections['row']['loop'];
$this->_sections['row']['step'] = 1;
$this->_sections['row']['start'] = $this->_sections['row']['step'] > 0 ? 0 : $this->_sections['row']['loop']-1;
if ($this->_sections['row']['show']) {
    $this->_sections['row']['total'] = $this->_sections['row']['loop'];
    if ($this->_sections['row']['total'] == 0)
        $this->_sections['row']['show'] = false;
} else
    $this->_sections['row']['total'] = 0;
if ($this->_sections['row']['show']):

            for ($this->_sections['row']['index'] = $this->_sections['row']['start'], $this->_sections['row']['iteration'] = 1;
                 $this->_sections['row']['iteration'] <= $this->_sections['row']['total'];
                 $this->_sections['row']['index'] += $this->_sections['row']['step'], $this->_sections['row']['iteration']++):
$this->_sections['row']['rownum'] = $this->_sections['row']['iteration'];
$this->_sections['row']['index_prev'] = $this->_sections['row']['index'] - $this->_sections['row']['step'];
$this->_sections['row']['index_next'] = $this->_sections['row']['index'] + $this->_sections['row']['step'];
$this->_sections['row']['first']      = ($this->_sections['row']['iteration'] == 1);
$this->_sections['row']['last']       = ($this->_sections['row']['iteration'] == $this->_sections['row']['total']);
?>
			<?php echo $this->_tpl_vars['pages'][$this->_sections['row']['index']]['0']; ?>

			<?php endfor; endif; ?>
			</div>
			<?php else: ?>
			<table width="480" border="0" cellspacing="0" cellpadding="0" id="table">
			没有留言...
			</table>
			<?php endif; ?>
	  </div><!-- book_a -->
	  <div id="book_b">
	  		<div id="ni"></div>
			
			<form name="from1" id="from1" method="post" action="book.php?action=add">
			<table border="0" cellspacing="0" cellpadding="0" id="fortab">
			<tr>
			<td>标题*：</td>
			<td><input name="title" type="text"/></td>
			</tr>
			<tr>
			<td>姓名*：</td>
			<td><input name="name" type="text" /></td>
			</tr>
			<tr>
			<td>Email*：</td>
			<td><input name="email" type="text" /></td>
			</tr>
			<tr>
			<td>浏览权限：</td>
			<td><select name="select">
    			<option value="all">所有人</option>
    			<option value="mst">管理员</option>
				</select>
			</td>
			
			<tr>
			<td>验证码*：</td>
			<td><input name="capt" type="text" size="5" maxlength="4" />
			<img id='rand' src='captcha.php'></img><a href='javascript:chk()'>看不清楚</a></td>
			</tr>
			
			</tr>
			<tr>
			<td>内容*：</td>
			<td><textarea name="ms" rows="10"/></textarea></td>
			</tr>
			</table>
			<input type="submit" name="submit" value="提交" class="submails" />
			</form>

	  </div><!-- book_b -->
	</div> <!-- tr -->
	</div> <!-- tl -->
  </div> <!-- centerby -->
</div> <!-- center -->
