<!--#include virtual ="./conn.asp"-->
<%dim id,sql
id = Cint(request.form("id"))
sql="select * from news where id ='"&id&"'"
set rs=server.CreateObject("ADODB.recordset")
rs.open sql,conn,1,1
%>
<%
dim sql2
set rs2 = server.CreateObject("adodb.recordset")
sql2 ="select * from nType "
rs2.open sql2,conn,1,1
%>
<table width="84%" height="185" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#00FF66">
<form action="xiugai_success.asp" name="form" method="post">
<input type="hidden" name="id" value="<%=rs.fields("id")%>">
<tr>
<td width="21%" align="center" bgcolor="#FFFFFF">新闻类别:</td>
<td width="44%" bgcolor="#FFFFFF">
<select name="cate">
<%
while not rs2.eof
%>
<option value="<%=rs2("tid")%>" <%if rs2("tid")=id then%> selected <%end if%>><%=rs2("ntype")%></option>
<%
rs2.movenext
wend
%>
<%rs2.close
set rs2=nothing
%>
</select>
</td>
<td width="35%" bgcolor="#FFFFFF">*必须填写</td>
</tr>
<tr>
<td align="center" bgcolor="#FFFFFF">新闻标题:</td>
<td bgcolor="#FFFFFF"><input type="text" name="title" value="<%=rs.fields("Title")%>">
<td bgcolor="#FFFFFF">*新闻标题不能为空</td>
</tr>
<tr>
<td align="center" bgcolor="#FFFFFF">新闻内容:</td>
<td bgcolor="#FFFFFF"><textarea name="content" rows="10" cols="50"><%=rs.fields("Content")%></textarea></td>
<td bgcolor="#FFFFFF">*新闻内容不能为空!</td>
</tr>
<tr>
<td colspan="3" bgcolor="#FFFFFF"><center><input name="sub" type="submit" value="修改新闻"></center></td>
</tr>
</form>
</table>