<?php
/**
 * 解梦内容编辑
 * $Id: product_category_new_input.inc,v 1.1 2015/10/08 11:18:53 wanggb Exp $
 * @author wanggb
 * @access public
 * @package manager.templates
 **/

?>
<b>题库添加/编辑</b><br />
<br />
<form name="subject_data_edit" action="subject_dat_edit_result.php" method="post" enctype="multipart/form-data">
<input type="hidden" name="action_type" value="<?=$action_type ?>" />
<input type="hidden" name="id" value="<?=$id ?>" />
<table width="80%">
	<tr>
		<td>项目</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<select name="category_id" style="width:200px;">
				<?
					foreach ($subject_category_list as $tmp) {
				?>
					<option value="<?=$tmp->id ?>" <?=$subject_dat->category_id == $tmp->id ? " selected " : "" ?>><?=$tmp->title ?></option>
				<?
					}
				?>
			</select>
		</td>
	</tr>
	<tr>
		<td>题目</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<textarea name="title" id="title" cols=60 rows=3?><?=htmlspecialchars($subject_dat->title) ?></textarea>
		</td>
	</tr>
	<tr>
		<td>MP3(听力题目用)</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<input type="file" id="upload_mp3_file" name="upload_mp3_file" accept=".mp3"/>
		</td>
	</tr>	
	<tr>
		<td>选项1</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<input type="text" id="selection1" name="selection1" value="<?=$subject_dat->selection1?>" size=40/>
		</td>
	</tr>
	<tr>
		<td>选项2</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<input type="text" id="selection2" name="selection2" value="<?=$subject_dat->selection2?>" size=40/>
		</td>	</tr>
	<tr>
		<td>选项3</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<input type="text" id="selection3" name="selection3" value="<?=$subject_dat->selection3?>" size=40/>
		</td>	</tr>
	<tr>
		<td>选项4</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<input type="text" id="selection4" name="selection4" value="<?=$subject_dat->selection4?>" size=40/>
		</td>
	</tr>
	<tr>
		<td>用法描述</td>
	</tr>
	<tr>
		<td class="begin_blank"><textarea name="comment" cols=60 rows=2?><?=htmlspecialchars($subject_dat->comment) ?></textarea></td>
	</tr>
	<tr>
		<td>正确答案</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<select name="right_answer" style="width:150px;">
				<?
					for($index=1; $index<=4; $index++) {
				?>
					<option value="<?=$index ?>" <?=$subject_dat->right_answer == $index ? " selected " : "" ?>>选择项<?=$index ?></option>
				<?
					}
				?>
			</select>
		</td>
	</tr>
	<tr>
		<td>难度</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<select name="level" style="width:150px;">
				<?
					for($index=5; $index>=1; $index--) {
				?>
					<option value="N<?=$index ?>" <?=$subject_dat->level == "N" . $index ? " selected " : "" ?>>N<?=$index ?></option>
				<?
					}
				?>
			</select>
		</td>
	</tr>
	<tr>
		<td>分值(参考等级考试)</td>
	</tr>
	<tr>
		<td class="begin_blank">
			<input type="text" id="point" name="point" value="<?=$subject_dat->point?>" size=20/>
		</td>
	</tr>
</table>
<br />
<input type="button" value="提交" class="button_width_normal" onClick="doCheck();"/>
</form>
