<!-- {include file="header.html"} -->
<div id="currentPosition">
	<p>{lang your_current_position} {lang trade_management} &raquo; {lang industry_news}</p>
</div>
<div id="rightTop"> 
    <h3>{lang industry_news}</h3> 
    <ul class="subnav">
		<li><a href="news.php">{lang management}</a></li>
        <li><a href="newstopic.php">{lang topic_news}</a></li>
        <li><a href="newstype.php">{lang sorts}</a></li>
        <li><a class="btn1" href="newstype.php?do=edit"><span>{lang add_or_edit}</span></a></li>
		<li><a href="newsgather.php">{lang collection}</a></li>
    </ul>
</div>
<div class="info">
  <form method="post" action="newstype.php" id="EditFrm" name="edit_frm">
  <input type="hidden" name="page" value="{$smarty.get.page}" />
    <table class="infoTable">
	  {if $smarty.get.id}
	  <input type="hidden" name="id" value="{$item.id}" />
      <tr>
        <th class="paddingT15"> {lang serial_number}{lang colon}</th>
        <td class="paddingT15 wordSpacing5"><input class="infoTableInput2" name="data[newstype][id]" value="{$item.id}" type="text" /><label class="field_notice">{lang do_not_change_non_special_need}</label>        </td>
      </tr>
      <tr>
        <th class="paddingT15"> {lang category_name}{lang colon}</th>
        <td class="paddingT15 wordSpacing5"><input class="infoTableInput2" name="data[newstype][name]" value="{$item.name}" type="text" /><label class="field_notice">{lang top_category_name_not_support_special_sign}</label>        </td>
      </tr>
		{else}
			  <tr>
			<th class="paddingT15"> {lang category_name}{lang colon}</th>
			<td class="paddingT15 wordSpacing5"><textarea name="data[newstype][name]" id="dataNames"></textarea><label class="field_notice">{lang add_more_than_one_line_on_behalf_of_a_record}</label></td>
		  </tr>
		{/if}
      <tr>
        <th class="paddingT15"> {lang parent_categories}{lang colon}</th>
        <td class="paddingT15 wordSpacing5">
        <select name="data[newstype][parent_id]" id="NewstypeParentId">
        <option value="0">{lang top_categories}</option>
        {$NewstypeOptions}
        </select>
        </td>
      </tr>
      <tr>
        <th></th>
        <td class="ptb20">
			<input class="formbtn" type="submit" name="save" value="{lang save_and_pub}" />		</td>
      </tr>
    </table>
  </form>
</div>
<script>
var parent_id = "{$item.parent_id|default:0}";
</script>
<!--{literal}-->
<script>
jQuery(document).ready(function($) {
	$("#NewstypeParentId").val(parent_id)
})
</script>
<!--{/literal}-->
<!-- {include file="footer.html"} -->