有段代码如何能实现这个上面的选择表单,与下面的数据录入整合,原先是因为录入只能在跟目录下录入太麻烦了,这太费劲了,能不能加个自动选者加的板块想我那里录入就往那里录入,怎么加表单~~~帮帮小弟谢谢了~~~
<!--#include file="conn.asp"-->
<!--#include file="config.asp"-->
<%
set urs=server.createobject("adodb.recordset")
sql="select * from user where username='"&Session("MjdnBBSUname")&"'"
urs.open sql,conn,1,1
if urs.eof or urs.bof then
response.redirect "err.asp?id=nologin"
end if%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>发表新贴子</title>
<link rel="stylesheet" type="text/css" href="css.css">
<script language="JavaScript">
function validate()
{
if (document.form.title.value=="")
{
alert("标题不能为空!");
document.form.title.focus();
return false ;
}
//if (document.form.content.value=="")
//{
// alert("内容不能为空!");
// document.form.content.focus();
// return false ;
//}
if (document.form.count.value=="")
{
alert("请填写分数,0也可以,但不能保证您的问题能得到及时解答!");
document.form.count.focus();
return false ;
}
if (document.form.count.value > <%=urs("count")%>)
{
alert("您的总分不够("+document.form.count.value+")分,请重新给分!");
document.form.count.focus();
return false ;
}
if (document.form.count.value < 0)
{
alert("不能够给负的分数!您想作弊啊?当心扣信誉分!");
document.form.count.focus();
return false ;
}
if (parseInt(document.form.count.value) != 0 )
{if(!confirm("你确定要给("+document.form.count.value+")分来问这个问题吗?"))
return false;
}
}
function check(e)
{
var k = window.event.keyCode;
if (k < 48 || k > 57){
alert("你输入的不是数字!您想作弊啊?当心扣信誉分!")
window.event.keyCode = 0 ;}
}
</script>
</head>
<body>
<center>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="550">
<tr>
<td><font color="#FF0000"><b><%=Session("MjdnBBSUname")%>(<%=Session("rname")%>)</b></font> 在 <font color="#FF0000"><b>
<%
set trs1=server.createobject("adodb.recordset")
sqlt1="select * from deeptree where id="&request("id")
trs1.open sqlt1,conn,1,1
if trs1("parentid")<>"0" then
set trs2=server.createobject("adodb.recordset")
sqlt2="select * from deeptree where id="&trs1("parentid")
trs2.open sqlt2,conn,1,1
end if
%>
<%if trs1("parentid")<>"0" then%><%=trs2("content")%> <%end if%>
<%=trs1("content")%></b></font> 论坛发表新贴子: 使用说明 <br>
<font color="#FF0000">(请您对您的言行负责,遵守中华人民共和国有关法律、法规,尊重网上道德) </font><br>
发表问题前,建议搜索已有问题:http://search.mjdn.net </td>
</tr>
</table>
<hr color="#999999" width="550">
<form method="POST" action="postnewadd.asp?id=<%=request("id")%>" name=form onsubmit="return validate()">
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="550">
<tr>
<td>文章标题:<input type=hidden name=roomid value="<%=request("id")%>"></td>
<td>
<p align="right"><font color="red">给分:</font><input type=text size=4 name=count value=20 style="color: #3366CC; border: 1px solid #3366CC" onkeypress="check(this)">
(0-100分) </td>
</tr>
<tr>
<td colspan="2"><input type=text size=75 name=title style="color: #3366CC; border: 1px solid #3366CC"></td>
</tr>
<tr>
<td colspan="2">文章内容:</td>
</tr>
<tr>
<td colspan="2">
<textarea name="content" style="display:'none'"></textarea>
<iframe ID="eWebEditor1" src="ewebedit/ewebeditor.asp?id=content&style=bbs" frameborder="0" scrolling="no" width="550" HEIGHT="350"></iframe>
</td>
</tr>
<tr>
<td colspan="2"><input type="submit" value="提 问" border="0" name="B1" WIDTH="60" HEIGHT="20" class="formtext">
<INPUT name="B2" TYPE="reset" WIDTH="60" HEIGHT="20" class="formtext" value="重 写">
</td>
</tr>
<tr>
<td colspan="2"><font color="#FF0000">问题得到解决后请及时结帖给分。</font> <br>
结帖方法:点击帖子右上的“管理”链接,进入管理页面,在要给分的回复后的文本框中填写分数,然后输入自己的密码,点击“给分”按钮。结帖图例</td>
</tr>
</table>
</form>
</body>
</html>
<%=copyright%>