<form action="keyword.manage.php" id="form_modi" name="form_modi" method="post">
	<input type="hidden" name="action" value="update" />
    <table class="from_table">
		<tr>
			<th class="th2"><tpl> $langKeywordName </tpl>：</th>
			<td width="530" class="td1"><input name="txt_name" type="text" id="txt_name" class="txtinput"  size="50" value="<tpl> $keyword_array.keyword_name </tpl>" />
			<label style="display:none" for="txt_name" class="wrong" metaDone="true" generated="true"></label>			</td>
		</tr>
		<tr>
			<th class="th2"><tpl> $langKeywordSeachDegree </tpl>：</th>
			<td width="530" class="td1"><input name="txt_num" type="text" id="txt_num" class="txtinput" size="50" value="<tpl> $keyword_array.keyword_num </tpl>" />
			<label style="display:none" for="txt_num" class="wrong" metaDone="true" generated="true"></label>			</td>
		</tr>
		<tr>
    		<td>
		</td>
    	    <td width="530">
			  <span class="btn_left">
			  <input type="submit" name="Submit" value="<tpl> $langKeywordSubmit </tpl>" class="btn_submit"/></span>
			  <input type="hidden" name="txt_id" id="txt_id" value="<tpl> $keyword_array.keyword_id </tpl>" />
		  </td>
		</tr>
    </table>
</form>
<script>
$(document).ready(function() {

	hideLoading();
	var options = {
		beforeSubmit:  function(){showLoading(showSaveText);},
		success:       function(msg){
							hideLoading();
							showMessage(msg.message,msg.type);
							if(msg.type == '1'){
								ShowDiv	= 'result_content';
								getPageContent("keyword.manage.php?action=ajax_list");
							}
						},
		type:      'post',
		dataType:  'json'
	};
	
	//对添加表单做的验证定义
	$("#form_modi").validate({
		errorClass: "wrong",
		rules: {
			txt_name: {required:true},
			txt_num: {required:true,number:true}
		},
		messages: {
			txt_name: {required:"<tpl> $langKeywordNotNull </tpl>"},
			txt_num: {required:"<tpl> $langKeywordSeachDegreeNotNull </tpl>",number:"<tpl> $langKeywordClassIsNumber </tpl>"}
		},
		submitHandler: function() {
			$('#form_modi').ajaxSubmit(options);
		}
	});
});
</script>