有二个源文件
源码1:
<TABLE align=center border=0 cellPadding=0 cellSpacing=1
width="96%">
<TBODY>
<TR>
<TD >
<%if onlinelook=1 then%>
<TABLE align=center border=0 cellPadding=0 cellSpacing=0
width="100%">
<TBODY>
<TR>
<TD vAlign=top width="10%">
<TABLE border=0 cellPadding=0 cellSpacing=0 width="100%">
<TBODY>
<TR>
<TD height=10></TD></TR>
<TR>
<TD>
<DIV align=center><IMG height=40
src="images/cd/play_list.jpg" width=112
border=0></DIV></TD></TR></TBODY></TABLE></TD>
<TD height=36 width="83%"><%
sql="select * from movieurl where nameid='"&articleid&"'"
set rsurl=server.createobject("adodb.recordset")
if onlinelook=1 then
rsurl.open sql,conn,1,1
if rsurl.eof then
response.write "没有提供在线观看"
else
no=rsurl.recordcount
%>
<%c=1
do while not rsurl.eof
%>
<TABLE border=0 cellPadding=0 cellSpacing=0>
<TBODY>
<TR>
<TD background=img/flyvbg01.gif height=19
width=29><DIV align=center><a href="javascript:OpenWindow('look.asp?id1=<%=rsurl("id")%>&id2=<%=articleid%>',580,480);"><FONT
color=#FF6400><%=c%></FONT></A></DIV></TD>
<%rsurl.movenext
c=c+1
%>
<%if rsurl.eof then%>
<%else%>
</TR>
</TBODY>
</TABLE>
<%loop
end if
rsurl.close
set rsurl=nothing
else
response.write "没有提供在线观看"
end if%>
还有一个是源码2:
<TD align="center">
<table width="80%" border="0" cellspacing="0" cellpadding="0">
<tr>
<%set rspy=server.createobject("adodb.recordset")
rspy.open "select sou from home",conn,1,3
%>
<% if rspy("sou")="12" then%>
<%
set rsurl=server.createobject("adodb.recordset")
sql="select * from movieurl where nameid='"&articleid&"'"
if rs("onlinelook")=1 then
rsurl.open sql,conn,1,1
serverip=rs("serverip")
set rst=server.createobject("adodb.recordset")
sql="select ipsip from movie where id="&serverip
rst.open sql,conn,1,1
if rsurl.eof then
response.write "没有提供在线观看"
else
no=rsurl.recordcount
if no=1 then%>
<a href="<%=rst("ipsip")%><%=rsurl("url")%>">
<font color="#cc3300"> <b> →<%=title%>←</b></font></a>
<% elseif no=2 then
%>
<a href="<%=rst("ipsip")%><%=rsurl("url")%>">
<font color="#cc3300"> <b>上集</b></font></a>
<%rsurl.movenext%>
<a href="<%=rst("ipsip")%><%=rsurl("url")%>">
<font color="#cc3300"> <b>下集</b></font></a>
<%elseif no=3 then%>
<a href="<%=rst("ipsip")%><%=rsurl("url")%>">
<font color="#cc3300"> <b>上集</b></font></a>
<%rsurl.movenext%>
<a href="<%=rst("ipsip")%><%=rsurl("url")%>">
<font color="#cc3300"> <b>中集</b></font></a>
<%rsurl.movenext%>
<a href="<%=rst("ipsip")%><%=rsurl("url")%>">
<font color="#cc3300"> <b>下集</b></font></a>
<%elseif no>3 then
c=1
do while not rsurl.eof
for c=1 to no
%>
<td width="22" background="img/real2.gif" align="center">
<a href="<%=rst("ipsip")%><%=rsurl("url")%>">
<font color="#ff9966"> <b>
<%=c%></b></font></a></td><td> </td>
<% if c mod 15=0 then%>
</tr>
<tr>
<td height="3"></td>
</tr>
<tr>
<%
end if
rsurl.movenext
if rsurl.eof then exit do
next
loop
rst.close
end if
end if
rsurl.close
else
response.write "不提供在线观看"
end if
%>
请问一下如何把源码2的:
serverip=rs("serverip")
set rst=server.createobject("adodb.recordset")
sql="select ipsip from movie where id="&serverip
rst.open sql,conn,1,1
这部份套用到源码1,好让源码1也能够<a href="<%=rst("ipsip")%><%=rsurl("url")%>">这样子读取URL
二个源码的数据库是相同的,数值等等也一样,