就是在生成HTML的时候,生成
<script language='javascript' src=hit.asp?id=<%=rs("id")%>></script>
hit.asp:
<!--#include file="articleconn.asp"-->
<%
newsid=CInt(request("id"))
sql="select hits from article where newsid="&newsid
set rs=conn.execute(sql)
hits=rs("hits")
%>
document.write("<%=rs("hits")%>")