谢谢
好帖!请问楼主,下面程序为何出错?
<%
Option Explicit
Response.contentType="text/xml"
dim conn,connstr,rs,sql,i,name,company,relation,url,msg,a,b,ab
relation=Request.Form("Relation")
url=Request.Form("Url")
msg=Request.Form("Msg")
a=Cint(Request.Form("a"))
b=Cint(Request.Form("b"))
ab=Cint(Request.Form("ab"))
i=1
connstr="provider=Microsoft.Jet.OLEDB.4.0;data source="&Server.MapPath("Msg.mdb")&";"
set conn=Server.CreateObject("ADODB.Connection")
set rs=Server.CreateObject("ADODB.RecordSet")
conn.open connstr
sql="Insert into data (Name,Company,Relation,Url,Msg) values ('"&name&"','"&company&"','"&relation&"','"&url&"','"&msg&"')"
conn.Execute(sql)
sql="select top 100 [name],[company] from [Msg] order by id desc"
rs.open sql,conn,1,1
Response.Write("<?xml version='1.0' encoding='utf-8'?><方圆寸苑网站>")
do while not rs.eof
Response.Write("<Result><name>"&rs("name")&"</name><score>"&rs("company"))&"</score></Result>"
rs.movenext
i=i+1
loop
Response.Write("</方圆寸苑网站>")
rs.close
conn.close
set rs=nothing
set conn=nothing
%>
[ 本帖最后由 kjf_x 于 2010-6-3 08:25 编辑 ]