asp表格movenext的问题,高手请指教
<%dowhilenotrs.eof%><TABLEcellSpacing=0cellPadding=2width="100%"border=0bgcolor="#FFF...
<% do while not rs.eof %>
<TABLE cellSpacing=0 cellPadding=2 width="100%" border=0 bgcolor="#FFFFFF">
<TBODY>
<TR>
<TD vAlign=middle width="79%" height=1><TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<% set rs=server.createobject("adodb.recordset")
sql="select * from company"
rs.open sql,conn,1,1
r1=rs.recordcount
rs.close
set rs=nothing
set rs=server.createobject("adodb.recordset")
sql="select * from zp order by id desc"
rs.open sql,conn,1,1
jobnum=rs.recordcount %>
<TD width="6%"><IMG src="../Images/qz_3.gif" alt=点击显示详细信息
name=viewimg1 width="16" height="11" onclick="javascript:view_xiangmu('hidden1','viewimg1');"></TD>
<TD width="94%"><SPAN class=p9-13><FONT color=#ffffff><B><A style="COLOR: black" href="javascript:view_xiangmu('hidden1','viewimg1');">点击我展开以下内容</b></TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
<TR>
<TD width="79%" height=1><TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<TD width="93%"><DIV id=hidden1 style="DISPLAY: none">
<TABLE height="95%" cellSpacing=0 cellPadding=0 width=92% align=center
border=0>
<TBODY>
<TR>
<TD colSpan=2><TABLE cellSpacing=0
cellPadding=0 border=0>
<TBODY>
<TR>
<TD width=27 rowSpan=2> </TD>
<TD width="416" class=WithBreaks><table width="100%" border="0" cellspacing="0" cellpadding="3">
<tr>
<td>
<img src="images/dot4.gif"> <FONT color=#000099><a href="javascript:person('Main/job.asp?uid=<%=rs("uname")%>&id=<%=rs("id")%>')" alt="点击查看详细介绍"><FONT color=#000099><%=rs("job")%></font></a>:</font><%=rs("sexs")%> <%=rs("nianlings")%> <%=rs("edus")%>
</td>
</tr> </table></TD>
</TR>
<TR>
<TD></TD>
</TR>
</TBODY>
</TABLE>
<TABLE cellSpacing=0
cellPadding=0 width=443 border=0>
</TABLE></TD>
</TR>
</TBODY>
</TABLE>
</DIV>
点击后即显示的隐藏内容 </TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
</TBODY>
</TABLE>
<% c=c+1
rs.movenext
if c>=10 then exit do
loop
rs.close
set rs=nothing %>
***************************************************************
以上自动循环9个表格,可是javascript:view_xiangmu('hidden1','viewimg1')里的"hidden1"和"viewimg1"不会相应的变为"hidden2"和"viewimg2",导至程序出错
如果哪位高手知道怎么设计,麻烦指教一下,本人将以30个Q币答谢,QQ:7762072 展开
<TABLE cellSpacing=0 cellPadding=2 width="100%" border=0 bgcolor="#FFFFFF">
<TBODY>
<TR>
<TD vAlign=middle width="79%" height=1><TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<% set rs=server.createobject("adodb.recordset")
sql="select * from company"
rs.open sql,conn,1,1
r1=rs.recordcount
rs.close
set rs=nothing
set rs=server.createobject("adodb.recordset")
sql="select * from zp order by id desc"
rs.open sql,conn,1,1
jobnum=rs.recordcount %>
<TD width="6%"><IMG src="../Images/qz_3.gif" alt=点击显示详细信息
name=viewimg1 width="16" height="11" onclick="javascript:view_xiangmu('hidden1','viewimg1');"></TD>
<TD width="94%"><SPAN class=p9-13><FONT color=#ffffff><B><A style="COLOR: black" href="javascript:view_xiangmu('hidden1','viewimg1');">点击我展开以下内容</b></TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
<TR>
<TD width="79%" height=1><TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<TD width="93%"><DIV id=hidden1 style="DISPLAY: none">
<TABLE height="95%" cellSpacing=0 cellPadding=0 width=92% align=center
border=0>
<TBODY>
<TR>
<TD colSpan=2><TABLE cellSpacing=0
cellPadding=0 border=0>
<TBODY>
<TR>
<TD width=27 rowSpan=2> </TD>
<TD width="416" class=WithBreaks><table width="100%" border="0" cellspacing="0" cellpadding="3">
<tr>
<td>
<img src="images/dot4.gif"> <FONT color=#000099><a href="javascript:person('Main/job.asp?uid=<%=rs("uname")%>&id=<%=rs("id")%>')" alt="点击查看详细介绍"><FONT color=#000099><%=rs("job")%></font></a>:</font><%=rs("sexs")%> <%=rs("nianlings")%> <%=rs("edus")%>
</td>
</tr> </table></TD>
</TR>
<TR>
<TD></TD>
</TR>
</TBODY>
</TABLE>
<TABLE cellSpacing=0
cellPadding=0 width=443 border=0>
</TABLE></TD>
</TR>
</TBODY>
</TABLE>
</DIV>
点击后即显示的隐藏内容 </TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
</TBODY>
</TABLE>
<% c=c+1
rs.movenext
if c>=10 then exit do
loop
rs.close
set rs=nothing %>
***************************************************************
以上自动循环9个表格,可是javascript:view_xiangmu('hidden1','viewimg1')里的"hidden1"和"viewimg1"不会相应的变为"hidden2"和"viewimg2",导至程序出错
如果哪位高手知道怎么设计,麻烦指教一下,本人将以30个Q币答谢,QQ:7762072 展开
1个回答
展开全部
<%
c=1
do while not rs.eof %>
<TABLE cellSpacing=0 cellPadding=2 width="100%" border=0 bgcolor="#FFFFFF">
<TBODY>
<TR>
<TD vAlign=middle width="79%" height=1><TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<% set rs=server.createobject("adodb.recordset")
sql="select * from company"
rs.open sql,conn,1,1
r1=rs.recordcount
rs.close
set rs=nothing
set rs=server.createobject("adodb.recordset")
sql="select * from zp order by id desc"
rs.open sql,conn,1,1
jobnum=rs.recordcount %>
<TD width="6%"><IMG src="../Images/qz_3.gif" alt=点击显示详细信息
name=viewimg1 width="16" height="11" onclick="javascript:view_xiangmu('hidden<%=c%>','viewimg<%=c%>');"></TD>
<TD width="94%"><SPAN class=p9-13><FONT color=#ffffff><B><A style="COLOR: black" href="javascript:view_xiangmu('hidden<%=c%>','viewimg<%=c%>');">点击我展开以下内容</b></TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
<TR>
<TD width="79%" height=1><TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<TD width="93%"><DIV id=hidden1 style="DISPLAY: none">
<TABLE height="95%" cellSpacing=0 cellPadding=0 width=92% align=center
border=0>
<TBODY>
<TR>
<TD colSpan=2><TABLE cellSpacing=0
cellPadding=0 border=0>
<TBODY>
<TR>
<TD width=27 rowSpan=2> </TD>
<TD width="416" class=WithBreaks><table width="100%" border="0" cellspacing="0" cellpadding="3">
<tr>
<td>
<img src="images/dot4.gif"> <FONT color=#000099><a href="javascript:person('Main/job.asp?uid=<%=rs("uname")%>&id=<%=rs("id")%>')" alt="点击查看详细介绍"><FONT color=#000099><%=rs("job")%></font></a>:</font><%=rs("sexs")%> <%=rs("nianlings")%> <%=rs("edus")%>
</td>
</tr> </table></TD>
</TR>
<TR>
<TD></TD>
</TR>
</TBODY>
</TABLE>
<TABLE cellSpacing=0
cellPadding=0 width=443 border=0>
</TABLE></TD>
</TR>
</TBODY>
</TABLE>
</DIV>
点击后即显示的隐藏内容 </TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
</TBODY>
</TABLE>
<% c=c+1
rs.movenext
if c>=10 then exit do
loop
rs.close
set rs=nothing %>
注意这段:
<TD width="6%"><IMG src="../Images/qz_3.gif" alt=点击显示详细信息
name=viewimg1 width="16" height="11" onclick="javascript:view_xiangmu('hidden<%=c%>','viewimg<%=c%>');"></TD>
c=1
do while not rs.eof %>
<TABLE cellSpacing=0 cellPadding=2 width="100%" border=0 bgcolor="#FFFFFF">
<TBODY>
<TR>
<TD vAlign=middle width="79%" height=1><TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<% set rs=server.createobject("adodb.recordset")
sql="select * from company"
rs.open sql,conn,1,1
r1=rs.recordcount
rs.close
set rs=nothing
set rs=server.createobject("adodb.recordset")
sql="select * from zp order by id desc"
rs.open sql,conn,1,1
jobnum=rs.recordcount %>
<TD width="6%"><IMG src="../Images/qz_3.gif" alt=点击显示详细信息
name=viewimg1 width="16" height="11" onclick="javascript:view_xiangmu('hidden<%=c%>','viewimg<%=c%>');"></TD>
<TD width="94%"><SPAN class=p9-13><FONT color=#ffffff><B><A style="COLOR: black" href="javascript:view_xiangmu('hidden<%=c%>','viewimg<%=c%>');">点击我展开以下内容</b></TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
<TR>
<TD width="79%" height=1><TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<TD width="93%"><DIV id=hidden1 style="DISPLAY: none">
<TABLE height="95%" cellSpacing=0 cellPadding=0 width=92% align=center
border=0>
<TBODY>
<TR>
<TD colSpan=2><TABLE cellSpacing=0
cellPadding=0 border=0>
<TBODY>
<TR>
<TD width=27 rowSpan=2> </TD>
<TD width="416" class=WithBreaks><table width="100%" border="0" cellspacing="0" cellpadding="3">
<tr>
<td>
<img src="images/dot4.gif"> <FONT color=#000099><a href="javascript:person('Main/job.asp?uid=<%=rs("uname")%>&id=<%=rs("id")%>')" alt="点击查看详细介绍"><FONT color=#000099><%=rs("job")%></font></a>:</font><%=rs("sexs")%> <%=rs("nianlings")%> <%=rs("edus")%>
</td>
</tr> </table></TD>
</TR>
<TR>
<TD></TD>
</TR>
</TBODY>
</TABLE>
<TABLE cellSpacing=0
cellPadding=0 width=443 border=0>
</TABLE></TD>
</TR>
</TBODY>
</TABLE>
</DIV>
点击后即显示的隐藏内容 </TD>
</TR>
</TBODY>
</TABLE></TD>
</TR>
</TBODY>
</TABLE>
<% c=c+1
rs.movenext
if c>=10 then exit do
loop
rs.close
set rs=nothing %>
注意这段:
<TD width="6%"><IMG src="../Images/qz_3.gif" alt=点击显示详细信息
name=viewimg1 width="16" height="11" onclick="javascript:view_xiangmu('hidden<%=c%>','viewimg<%=c%>');"></TD>
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询