| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 1060 人关注过本帖
标题:如何实现商品滚动的效果
只看楼主 加入收藏
bajun
Rank: 1
来 自:哈弗大学牛津国际学院
等 级:新手上路
帖 子:178
专家分:0
注 册:2007-8-9
结帖率:100%
收藏
 问题点数:0 回复次数:1 
如何实现商品滚动的效果
<MARQUEE scrollAmount=1 scrollDelay=50 width=460 height="130" direction="up" align="center" onMouseOver="this.stop()" onMouseOut="this.start()">
               
          <%  
           sql = "select  * from Eas_News_List where ns_ntid = 119 and ns_check = 1 order by ns_time desc"
           set rs = ado_query(sql,conn)
            while not rs.eof
          %>
                
                  <td width="34%" height="130" valign="top">
                  
                  <table border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>
                <td width="10" height="86"><img src="Images/菱克特尔_r5_c4.png" width="10" height="81" /></td>
                <td width="113" valign="middle"><table width="113" height="81" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td width="113" height="10" valign="top" background="Images/菱克特尔_r5_c6.png"></td>
                  </tr>
                  <tr>
                    <td height="62"><%
                              if file_exists("EasCMS/$EasDB/UpFiles/News/"&rs("ns_image"),1) then
                                 echo "<a href=""productshow.asp?ns_id="&rs("ns_id")&"&ns_ntid="&rs("ns_ntid")&""" title=""点" &_
                                  "击查看详细信息"" target=""_blank"" onFocus=""this.blur()""><img src=""EasCMS/$EasDB/UpFiles/News/"&rs("ns_image")&""" width=""150"" height=""62"" border=""0""/></a>"
                                else
                                   echo "<a href=""productshow.asp?ns_id="&rs("ns_id")&"&ns_ntid="&rs("ns_ntid")&""" title=""点" &_
                                      "击查看详细信息"" onFocus=""this.blur()""><img src='Images/pic_2.jpg'  border=""0"" width=""150"" height=""62""></a>"
                              end if
                          %></td>
                  </tr>
                  <tr>
                    <td height="9" background="Images/菱克特尔_r5_c6.png"></td>
                  </tr>
                </table></td>
                <td width="10"><div align="left"><img src="Images/菱克特尔_r5_c8.png" width="8" height="81" /></div></td>
              </tr>
              <tr>
                <td colspan="3"><div align="center"><span style="font-size: 12px; color: #999999"><%=rs("ns_skim")%></span></div></td>
              </tr>
              <tr>
                <td colspan="3">&nbsp;</td>
              </tr>
            </table>
        
            </td>
               
                 <%   rs.movenext
                         wend
                         if rs.recordcount = 0 then echo "暂无信息"
                    %>
                    </marquee>

我用marquee后 为什么不滚动 而且定义的宽度被撑开了
应该用什么方法好
搜索更多相关主题的帖子: 商品 效果 滚动 
2008-10-06 09:21
nicechlk
Rank: 3Rank: 3
等 级:论坛游侠
威 望:4
帖 子:330
专家分:187
注 册:2008-9-6
收藏
得分:0 
你应该仔细检查代码,这个你参考一下吧:
<tabel width="600" border="0" .....>
<tr><td height="30" width="160" class=....>
<marquee height="120" direction="up" onMouseOver="this.stop()" onMouseOut="this.start()" scrollamount="2">
<%循环语句,从数据库读取%>
</marquee>
</td></tr>
</table>
总之,marquee要在外围。

莫以善小而不为,莫以恶小而为之!
2008-10-06 14:10
快速回复:如何实现商品滚动的效果
数据加载中...
 
   



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

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