<!--#include file="conn.asp"-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>fa</title>
<style type="text/css">
<!--
.style1 {font-size: 14px}
-->
</style>
<% if request("post"
<>""then
if request("user"
=""or request("utext"
=""then
response.Write "<font color=red size=10> 请填写完整信息!</font><br><font color=red size=10><a href=fa.asp>返回</a></font>"
call closedb
else
set rs=Server.CreateObject("ADODB.recordset"
rs.open "select *from utext",conn,1,3
rs.addnew()
rs("user"
=request("user"
rs("utext"
=request("utext"
rs("utime"
=now()
rs.update
rs.close
rs=nothing
call closedb
end if
end if
%>
</head>
<body>
<form name="form" action="fa.asp" method="post">
<table width="60%" border="0" align="center" cellspacing="0">
<tr>
<td width="20%"><div align="center" class="style1">用户名:</div></td>
<td><input type="text" name="user" height="20"></td>
<td> </td>
</tr>
<tr>
<td><div align="center"><span class="style1">内 容:</span></div></td>
<td height="320"><textarea name="utext" rows="20" wrap="VIRTUAL" id="utext"></textarea></td>
<td> </td>
</tr>
<tr>
<td> </td>
<td height="30"><input type="submit" name="Submit" value="提交">
<input type="reset" name="Submit2" value="重置" >
<input type="hidden" name="post" value="true">
</td>
<td> </td>
</tr>
</table></form>
</body>
</html>
以上为原文代码,请高手指点以下问题
1、当user或是utext为空时,怎么样只显示response后面的内容,不显示<form>
2、点解(为什么)我的数据库不能更新呢?说为只读状态!!