急求:在asp中点击按钮怎么才能让数据库中的东西显示在本页面中

来源:百度知道 编辑:UC知道 时间:2024/05/09 06:29:26
下边的好比是一个表格:

——————————————————————————

问题: 你叫什么名字?

———————————————————————————

答案:“按钮”( )

———— ——————————————————————

点击按狃怎么才能让答案显示在括号中,问题也是从数据库中掉出来的,答案也要从数据库中显示在本页面,

ASP怎么样才能实现啊,请高手帮忙,谢谢了!下边的是我的代码,

<!--#include file="conn.asp" -->
<!--#include file="sub.asp" -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>index</title>
</head>
<% set rss=server.CreateObject("adodb.recordset")
sql="select * from content order by id asc"
rss.open sql,conn,1,1 %>

<body>
<p>
<% do while not rss.eof %>
<table width="500" border="1" align="center">
<tr>
<td colspan="2"&g

将"答案字段名"替换为相应内容就OK了

<!--#include file="conn.asp" -->
<!--#include file="sub.asp" -->

<% set rss=server.CreateObject("adodb.recordset")
sql="select * from content order by id asc"
rss.open sql,conn,1,1
num_count=0
%>

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>index</title>
</head>
<body>
<script language="javascript">
function check_input(re_where,what)
{re_where.innerHTML=what
}
user_basic.rows[0].cells[4]
</script>
<table width="58%" border="0" cellspacing="0" cellpadding="0" id="aq">
<% do while not rss.eof %>
<tr>
<td width="52%"><%=rss("question