在<script>内部用asp语句输出js函数
<script><%setconn=server.CreateObject("ADODB.Conection")conn.open(...
<script> <% set conn=server.CreateObject("ADODB.Conection") conn.open("driver={Microsoft Access Driver (*.mdb)};dbq="&_ server.MapPath("person.mdb") set rs=server.CreateObject("ADODB.Recordset") sql="select * from g1 by id desc" rs.open sql,conn,3,1 rs.movefirst() while not rs.eof row="<table><tr>" for i=0 to rs.fields.count-1 row=row&"<td>"&rs(i)&"</td>" next response.Write(row&"</tr>") rs.movenext() wend conn.close() %> </script>
展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询