%%C9^C99^C9903263%%MST1423.tpl.php 9.26 KB
<?php /* Smarty version 2.6.26, created on 2018-04-01 22:54:27
         compiled from MST1423.tpl */ ?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
<META name="GENERATOR" content="Microsoft FrontPage 4.0">
<META http-equiv="Content-Type" content="text/html; charset=EUC-JP">
<META http-equiv="Content-Style-Type" content="text/css">
<link href="./css/style.css" rel="stylesheet" type="text/css">
<TITLE>め〜るNiポン!</TITLE>
<SCRIPT LANGUAGE="JavaScript">
<?php echo '
//********** 一覧へ戻る **********
function ichiranBack(){
	if (confirm("入力内容は破棄して回答パターン一覧画面に戻ります\\nよろしいですか?")){
		document.Frm.action="./MST1410.php";
		document.Frm.submit();
	}
}
//********** 入力チェック **********
function input_chk(flg){
	if(document.Frm.pattern_nm.value == ""){
		window.alert("回答パターン名称を入力してください。");
		document.Frm.pattern_nm.focus();
		return false;
	}
	if (confirm("この内容で登録します。\\nよろしいですか?")){
		if (flg == 1){
			document.Frm.action="MST1422.php";
			document.Frm.submit();
		}else{
			document.Frm.action="MST1421.php";
			document.Frm.submit();
		}
	}
}

//********** 解答欄変更 **********
function num_change(){
	document.Frm.action="MST1420.php";
	document.Frm.submit();
}
'; ?>

</SCRIPT>
</HEAD>
<BODY bgcolor="White">
<form name="Frm" method="POST">
<!-- ヘッダー表示 -->
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => 'header.tpl', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
<!-- メニュー表示 -->
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => 'menu.tpl', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
<!-- 一覧表示 -->
<CENTER>
<table width="100%" border="0">
	<tr>
		<th><B><FONT color=blue size=5>回答パターン登録</FONT></B></th>
	</tr>
</table>
<hr/>
<br>
<TABLE border=0 WIDTH="700">
	<TR>
		<TD>
			<CENTER>
				<INPUT type="button" name="back" value="一覧に戻る" onClick="JavaScript:ichiranBack();">
			</CENTER>
		</TD>
	</TR>
	<TR>
		<TD>
			<B><FONT size="2" color=#FF0000></FONT></B><FONT size="2">は入力必須項目です</FONT>
		</TD>
	</TR>
	<TR>
		<TD>
			<TABLE border=1 bordercolor="#008080" >
				<TR>
					<TD bgcolor="#FFCC99" WIDTH="150">
						<B><FONT size="2">回答パターン名称</FONT><FONT size="2" color=#FF0000></FONT></B>
					</TD>
					<TD>
						<INPUT maxlength="30" size="50" type="text" name="pattern_nm" value="<?php echo $this->_tpl_vars['pattern_nm']; ?>
">
						<B><FONT size="2">(英数字:最大30文字)</FONT></B>
					</TD>
				</TR>
				<TR>
					<TD bgcolor="#FFCC99"><B><FONT size="2">選択数</FONT></B></TD>
					<TD>
						<select name="select_nm" onChange="num_change();">
							<?php unset($this->_sections['cnt']);
$this->_sections['cnt']['name'] = 'cnt';
$this->_sections['cnt']['start'] = (int)0;
$this->_sections['cnt']['loop'] = is_array($_loop=$this->_tpl_vars['max_num']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['cnt']['show'] = true;
$this->_sections['cnt']['max'] = $this->_sections['cnt']['loop'];
$this->_sections['cnt']['step'] = 1;
if ($this->_sections['cnt']['start'] < 0)
    $this->_sections['cnt']['start'] = max($this->_sections['cnt']['step'] > 0 ? 0 : -1, $this->_sections['cnt']['loop'] + $this->_sections['cnt']['start']);
else
    $this->_sections['cnt']['start'] = min($this->_sections['cnt']['start'], $this->_sections['cnt']['step'] > 0 ? $this->_sections['cnt']['loop'] : $this->_sections['cnt']['loop']-1);
if ($this->_sections['cnt']['show']) {
    $this->_sections['cnt']['total'] = min(ceil(($this->_sections['cnt']['step'] > 0 ? $this->_sections['cnt']['loop'] - $this->_sections['cnt']['start'] : $this->_sections['cnt']['start']+1)/abs($this->_sections['cnt']['step'])), $this->_sections['cnt']['max']);
    if ($this->_sections['cnt']['total'] == 0)
        $this->_sections['cnt']['show'] = false;
} else
    $this->_sections['cnt']['total'] = 0;
if ($this->_sections['cnt']['show']):

            for ($this->_sections['cnt']['index'] = $this->_sections['cnt']['start'], $this->_sections['cnt']['iteration'] = 1;
                 $this->_sections['cnt']['iteration'] <= $this->_sections['cnt']['total'];
                 $this->_sections['cnt']['index'] += $this->_sections['cnt']['step'], $this->_sections['cnt']['iteration']++):
$this->_sections['cnt']['rownum'] = $this->_sections['cnt']['iteration'];
$this->_sections['cnt']['index_prev'] = $this->_sections['cnt']['index'] - $this->_sections['cnt']['step'];
$this->_sections['cnt']['index_next'] = $this->_sections['cnt']['index'] + $this->_sections['cnt']['step'];
$this->_sections['cnt']['first']      = ($this->_sections['cnt']['iteration'] == 1);
$this->_sections['cnt']['last']       = ($this->_sections['cnt']['iteration'] == $this->_sections['cnt']['total']);
?>  
								<option value="<?php echo $this->_sections['cnt']['index']; ?>
" 
								<?php if ($this->_tpl_vars['select_nm'] == $this->_sections['cnt']['index']): ?>
									selected
								<?php endif; ?>
								><?php echo $this->_sections['cnt']['index']; ?>

							<?php endfor; endif; ?> 
						</select>
						<BR>
						<FONT size=2><B>選択数0個の送信は、既読確認のみで回答を入力することはできません。</B></FONT>
					</TD>
				</TR>
				<?php unset($this->_sections['cnt']);
$this->_sections['cnt']['name'] = 'cnt';
$this->_sections['cnt']['start'] = (int)1;
$this->_sections['cnt']['loop'] = is_array($_loop=$this->_tpl_vars['select_nm']+1) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['cnt']['show'] = true;
$this->_sections['cnt']['max'] = $this->_sections['cnt']['loop'];
$this->_sections['cnt']['step'] = 1;
if ($this->_sections['cnt']['start'] < 0)
    $this->_sections['cnt']['start'] = max($this->_sections['cnt']['step'] > 0 ? 0 : -1, $this->_sections['cnt']['loop'] + $this->_sections['cnt']['start']);
else
    $this->_sections['cnt']['start'] = min($this->_sections['cnt']['start'], $this->_sections['cnt']['step'] > 0 ? $this->_sections['cnt']['loop'] : $this->_sections['cnt']['loop']-1);
if ($this->_sections['cnt']['show']) {
    $this->_sections['cnt']['total'] = min(ceil(($this->_sections['cnt']['step'] > 0 ? $this->_sections['cnt']['loop'] - $this->_sections['cnt']['start'] : $this->_sections['cnt']['start']+1)/abs($this->_sections['cnt']['step'])), $this->_sections['cnt']['max']);
    if ($this->_sections['cnt']['total'] == 0)
        $this->_sections['cnt']['show'] = false;
} else
    $this->_sections['cnt']['total'] = 0;
if ($this->_sections['cnt']['show']):

            for ($this->_sections['cnt']['index'] = $this->_sections['cnt']['start'], $this->_sections['cnt']['iteration'] = 1;
                 $this->_sections['cnt']['iteration'] <= $this->_sections['cnt']['total'];
                 $this->_sections['cnt']['index'] += $this->_sections['cnt']['step'], $this->_sections['cnt']['iteration']++):
$this->_sections['cnt']['rownum'] = $this->_sections['cnt']['iteration'];
$this->_sections['cnt']['index_prev'] = $this->_sections['cnt']['index'] - $this->_sections['cnt']['step'];
$this->_sections['cnt']['index_next'] = $this->_sections['cnt']['index'] + $this->_sections['cnt']['step'];
$this->_sections['cnt']['first']      = ($this->_sections['cnt']['iteration'] == 1);
$this->_sections['cnt']['last']       = ($this->_sections['cnt']['iteration'] == $this->_sections['cnt']['total']);
?>  
					<TR>
						<TD bgcolor="#FFCC99">
							<B><FONT size="2">回答パターン<?php echo $this->_sections['cnt']['index']; ?>
</FONT></B>
						</TD>
						<TD>
							<?php if ($this->_tpl_vars['name_nm'][$this->_sections['cnt']['index']] == ""): ?>
								<B><FONT size="2" color="#FF0000">※入力されていません。</FONT></B><br>
							<?php endif; ?>
							<INPUT maxlength="20" size="30" type="text" name="name_nm[<?php echo $this->_sections['cnt']['index']; ?>
]" value="<?php echo $this->_tpl_vars['name_nm'][$this->_sections['cnt']['index']]; ?>
">
							<B><FONT size="2">(英数字:最大30文字)</FONT></B>
							<input type="hidden" name="name<?php echo $this->_sections['cnt']['index']; ?>
_id" value="<?php echo $this->_sections['cnt']['index']; ?>
">
						</TD>
					</TR>
				<?php endfor; endif; ?> 
			</TABLE>
		</TD>
	</TR>
</TABLE>

<TABLE border=0 WIDTH="700">
	<TR>
		<td align="center">
			<input type="button" value="<?php echo $this->_tpl_vars['btn_value']; ?>
" onClick="return input_chk(<?php echo $this->_tpl_vars['exeflg']; ?>
);">
		</TD>
	</TR>
</TABLE>

</CENTER>

<input type="hidden" name="pattern_id" value="<?php echo $this->_tpl_vars['pattern_id']; ?>
">
<input type="hidden" name="default_flg" value="<?php echo $this->_tpl_vars['default_flg']; ?>
">
<input type="hidden" name="del_flg" value="<?php echo $this->_tpl_vars['del_flg']; ?>
">
<input type="hidden" name="exeflg" value="<?php echo $this->_tpl_vars['exeflg']; ?>
">
<input type="hidden" name="e" value="<?php echo $this->_tpl_vars['exeflg']; ?>
">
<input type="hidden" name="p" value="<?php echo $this->_tpl_vars['pattern_id']; ?>
">
<input type="hidden" name="scrflg" value="1">

<!-- フッター表示 -->
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => 'footer.tpl', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
</FORM>
</BODY>
</HTML>