<!--#include file="articleconn.asp"-->
<%
if request.cookies("adminok")="" then
  response.redirect "login.asp"
end if
%>
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 3.0">
<link rel="stylesheet" type="text/css" href="style.css">
<title>修改文章</title>
</head>

<body>

<form method="POST" action="saveedit.asp?id=<%=request("id")%>">
  <div align="center"><center><table border="1" cellspacing="0" width="80%" bordercolorlight="#000000" bordercolordark="#FFFFFF" cellpadding="0">
    <tr>
          <td width="100%" bgcolor="#eaeaea" height="20"> 
            <p>修 改 文 章 
          </td>
    </tr>
    <tr align="center">
      <td width="100%">
            <table border="0" cellspacing="1" width="100%">
              <%
dim sql
dim rs
 sql="select * from learning where articleid="&request("id")
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,1
title=rs("title")
con=rs("content")
rs.close
set rs=nothing
                %>
              <tr> 
                <td width="15%" align="right" height="30">文章标题：</td>
                <td width="85%" height="30"> 
                  <input type="text" name="txttitle" size="70"
          class="smallinput" maxlength="100" value="<%=title%>">
                </td>
              </tr>
              <tr> 
                <td align="right" height="30">文章栏目：</td>
                <td width="85%" height="30"> 
                  <select class="smallSel" name="typeid" size="1">
                    <%
dim rstype,typesql,sel
 set rstype=server.createobject("adodb.recordset")
  typesql="select * from type"
 rstype.open typesql,conn,1,1
			  do while not rstype.eof
                                sel="selected"    
		             response.write "<option " & sel & " value='"+CStr(rstype("typeID"))+"' name=typeid>"+rstype("type")+"</option>"+chr(13)+chr(10)
		             rstype.movenext
    		          loop
			rstype.close
			  %>
                  </select>
                  <font color="#FF0000">支持html</font> 
                  <input type="checkbox" name="checkbox" value="on">
                </td>
              </tr>
              <tr> 
                <td align="right" valign="top">文章内容：</td>
                <td width="85%"> 
                  <textarea rows="15" name="txtcontent" cols="70" class="smallarea"><%content=replace(con,"<br>",chr(13))
            content=replace(content,"&nbsp;"," ")
            response.write content%></textarea>
                </td>
              </tr>
            </table>
      </td>
    </tr>
  </table>
  </center></div><div align="center"><center><p><input type="submit" value=" 修 改 "
  name="cmdok" class="buttonface">&nbsp; <input type="reset" value=" 复 原 "
  name="cmdcancel" class="buttonface"></p>
  </center></div>
</form>
</body>
</html>
<% 
  conn.close  
  set conn=nothing  
%>
