代码如下:
<!--#include file="inc/conn.inc"-->
<!--#include file="inc/getxmlinfo.inc"-->
<%
id=request("id")
if not IsNumeric(id) then
btid=0
end if
if isnull(id) or id="" then
id=0
else
if clng(id)<=0 then
id=0
end if
end if
if id=0 then
%>
<HTML><HEAD><TITLE> BT免费下载</TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<LINK href="images/sty.css" type=text/css rel=stylesheet>
<BODY>
<!-- #include file="include/header.asp" -->
<TABLE cellSpacing=0 cellPadding=0 width="100%">
<TBODY>
<TR vAlign=top>
<TD width="100%">输入的信息编号非法!
</TD>
</TR>
</TBODY>
</TABLE>
<!-- #include file="include/footer.asp" -->
</BODY></HTML>
<% response.end
end if
sqlstring="select * from data_BTinfo where id="&id
rs.open sqlstring,conn
if rs.eof or rs.bof then%>
<HTML><HEAD><TITLE><%=rs("BTname")%> BT免费下载</TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<LINK href="images/sty.css" type=text/css rel=stylesheet>
<BODY>
<!-- #include file="include/header.asp" -->
<TABLE cellSpacing=0 cellPadding=0 width="100%">
<TBODY>
<TR vAlign=top>
<TD width="100%">输入的信息编号非法!
</TD>
</TR>
</TBODY>
</TABLE>
<!-- #include file="include/footer.asp" -->
</BODY></HTML>
<% rs.close
else
%>
<HTML><HEAD><TITLE><%=rs("BTname")%> BT免费下载</TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<LINK href="images/sty.css" type=text/css rel=stylesheet>
<BODY>
<!-- #include file="include/header.asp" -->
<TABLE cellSpacing=0 cellPadding=0 width="100%">
<TBODY>
<TR vAlign=top>
<TD width="100%">
<DIV id="HeadingOne">
<div>
<dl id="m_a">
<dt>[影视短片]-<%=rs("BTname")%></dt>
<dd>类型:<a href="default.asp?tj=1&keyword=<%=rs("BTtype")%>"><%=rs("BTtype")%></a></dd>
<%
if not isnull(rs("BTurl")) then
BTurl=rs("BTurl")
else
BTurl=""
end if
%>
<dd>资源标题:<%=rs("BTname")%></dd>
<dd>资源大小:<%=rs("BTsize")%></dd>
<dd>发布日期:<%=rs("BTdate")%></dd>
<%
if rs("bagid")=0 or isnull(rs("bagid")) then
bagid=0
else
bagid=rs("bagid")
end if
if rs("olddataid")=0 or isnull(rs("olddataid")) then
olddataid="0"
else
olddataid=cstr(rs("olddataid"))
end if
rs.close
%>
</dl>
</div>
<div>
<dl>
<dd><a href="<%=BTurl%>">第一下载点</a> <%if right(BTurl,8)<>".torrent" then%><a href="#" onclick="window.open ('<%=BTurl%>','sec1','height=300,width=200,toolbar=no,status=no,Top=60,Left=170,resizable=yes,scrollbars=yes');">第二下载点</a> <%end if%><a href="help/index.asp" target="_blank">如何下载?</a></dd>
</dl>
</div>
<div>
<dl>
<%
if bagid=0 then
call showfromdb(id)
else
call showfromxml(bagid,olddataid)
end if
%>
</dl>
</div>
</DIV></TD>
<TD>
<!-- #include file="include/infopagead.asp" -->
</TD></TR></TBODY></TABLE>
<div>
<DIV id=Feeds><DIV id=AtomRSS><B></B></DIV></DIV></DIV>
<%
end if
%>
<!-- #include file="include/footer.asp" -->
<%
call CloseConn()
%>
</BODY></HTML>
<%
sub showfromdb(id)
sqlstring="select * from contentinfo where id="&id
set rs=conn.execute(sqlstring)
if not (rs.eof or rs.bof) then
if not isnull(rs("delicacy")) then
%>
<dd><IMG onload="javascript:if(this.width>520)this.width=520;" src="<%=rs("delicacy")%>"></dd>
<%
end if
if not isnull(rs("direct")) then
%>
<dd>导演:<%=rs("direct")%></dd>
<%
end if
if not isnull(rs("playwright")) then
%>
<dd>编剧:<%=rs("playwright")%></dd>
<%
end if
if not isnull(rs("cast")) then
%>
<dd>演员表:<%=rs("cast")%></dd>
<%
end if
if not isnull(rs("ReleaseDates")) then
%>
<dd>上映日期:<%=rs("ReleaseDates")%></dd>
<%
end if
if not isnull(rs("country")) then
%>
<dd>国家:<%=rs("country")%></dd>
<%
end if
if not isnull(rs("language")) then
%>
<dd>语言:<%=rs("language")%></dd>
<%
end if
if not isnull(rs("color")) then
%>
<dd>色彩:<%=rs("color")%></dd>
<%
end if
if not isnull(rs("sound")) then
%>
<dd>声音:<%=rs("sound")%></dd>
<%
end if
if not isnull(rs("runningtime")) then
%>
<dd>时长:<%=rs("runningtime")%></dd>
<%
end if
if not isnull(rs("plotsummary")) then
%>
<dd>简介:<%=rs("plotsummary")%></dd>
<%
end if
end if
rs.close
end sub
sub showfromxml(bagid,olddataid)
On Error Resume Next
sqlstring="select bagxmlpath from data_BAGinfo where bagid="&bagid
set rs=conn.execute(sqlstring)
if not (rs.eof or rs.bof) then
bagxmlpath=rs(0)
bagxmlpath=replace(bagxmlpath,"../","")
readstatus="true"
set xmlobj = server.CreateObject("Microsoft.XMLDOM")
myxml= server.MapPath(bagxmlpath)
'response.write myxml
xmlobj.load(myxml)
if err=0 then
call showinfo(olddataid,xmlobj)
end if
end if
rs.close
end sub
%>
请稍微详细的给小弟说明一下,万分感谢!!!
对了还有 在加入一个 浏览次数 统计的代码?