| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 500 人关注过本帖
标题:[求助]图片怎么样才能让他横的排列 4个.然后自动换行..!!
只看楼主 加入收藏
xiaobo2008
Rank: 1
等 级:新手上路
帖 子:3
专家分:0
注 册:2007-4-19
收藏
 问题点数:0 回复次数:1 
[求助]图片怎么样才能让他横的排列 4个.然后自动换行..!!
<% sql="select top 8 title,adid,color,pic,type_two,type_three from china_data where pic <>'' and stop >= date() order by adid desc"
set rs=server.createobject("adodb.recordset")
rs.open sql,connstr,1,1
if rs.eof then %>
暂无工作犬信息!
<% rs.close
set rs=nothing
else
i=0
do while i<16 and not rs.eof %>
<td><div align="center"><img class="image_kuang" src="<% if lcase(left(rs("pic"),7))<>"http://" then%>adpic/<%end if%><%=rs("pic")%>"width="74" height="51" alt="<%=rs("title")%>" > <a title=<%=rs("title")%> href="html/<%=rs("adid")%>.htm" target="_blank"><font style="size:12px" <%if rs("color")<>"" then%>color="<%=rs("color")%>">
<%end if%>>
<%=left(rs("type_three"),4)%>&nbsp;<%=left(rs("type_two"),5)%></a>
</div>
<%i=i+4
rs.movenext
loop
rs.close
set rs=nothing
end if %>

[求助]图片怎么样才能让他横的排列 4个.然后自动换行..!!

搜索更多相关主题的帖子: 排列 pic eof 自动 
2007-04-21 19:57
lq7350684
Rank: 6Rank: 6
等 级:贵宾
威 望:20
帖 子:5089
专家分:98
注 册:2006-11-6
收藏
得分:0 
<% sql="select top 8 title,adid,color,pic,type_two,type_three from china_data where pic <>'' and stop >= date() order by adid desc"
set rs=server.createobject("adodb.recordset")
rs.open sql,connstr,1,1
if rs.eof then %>
暂无工作犬信息!
<% rs.close
set rs=nothing
else
dim i
do while i<16 and not rs.eof
i=i+1
%>
<td><div align="center"><img class="image_kuang" src="<% if lcase(left(rs("pic"),7))<>"http://" then%>adpic/<%end if%><%=rs("pic")%>"width="74" height="51" alt="<%=rs("title")%>" > <a title=<%=rs("title")%> href="html/<%=rs("adid")%>.htm" target="_blank"><font style="size:12px" <%if rs("color")<>"" then%>color="<%=rs("color")%>">
<%end if%>>
<%=left(rs("type_three"),4)%>&nbsp;<%=left(rs("type_two"),5)%></a>
</div>
<%if i mod 4=0 then response.white "<br>"
rs.movenext
loop
rs.close
set rs=nothing
end if %>
2007-04-22 11:41
快速回复:[求助]图片怎么样才能让他横的排列 4个.然后自动换行..!!
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.015561 second(s), 9 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved