求css+div滚动.不要marqueen.
<!DOCTYPEhtmlPUBLIC"-//W3C//DTDXHTML1.0Transitional//EN""http://www.w3.org/TR/xhtml1/...
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档 </title>
<style type="text/css">
.*{font-size:12px;}
.content {width:900px;margin:0 auto;}
.pic{padding:1px; border:1px solid #B0B0B0; margin:10px auto 0px 13px; float:left;}
.top_left {float:left;}
.new_pic{text-align:center;}
</style>
</head>
<body>
<div class="content box_bor" style="margin-top:0px; height:135px;">
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_01.jpg" width="130" height="100" border="0" /> </div> <br />
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_02.jpg" width="130" height="100" border="0" /> </div>
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_03.jpg" width="130" height="100" border="0" /> </div>
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_04.jpg" width="130" height="100" border="0" /> </div>
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_03.jpg" width="130" height="100" border="0" /> <br />
</div>
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_02.jpg" width="130" height="100" border="0" /> </div>
</div>
</div>
</body>
</html>
高手帮忙了.求滚动因为我把marqueen加上去之后.整个层都动了.
前边缺了一大块.要不是少一片marqueen其实也行的. 展开
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档 </title>
<style type="text/css">
.*{font-size:12px;}
.content {width:900px;margin:0 auto;}
.pic{padding:1px; border:1px solid #B0B0B0; margin:10px auto 0px 13px; float:left;}
.top_left {float:left;}
.new_pic{text-align:center;}
</style>
</head>
<body>
<div class="content box_bor" style="margin-top:0px; height:135px;">
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_01.jpg" width="130" height="100" border="0" /> </div> <br />
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_02.jpg" width="130" height="100" border="0" /> </div>
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_03.jpg" width="130" height="100" border="0" /> </div>
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_04.jpg" width="130" height="100" border="0" /> </div>
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_03.jpg" width="130" height="100" border="0" /> <br />
</div>
</div>
<div class="new_pic top_left">
<div class="pic"> <img src="images/pic_02.jpg" width="130" height="100" border="0" /> </div>
</div>
</div>
</body>
</html>
高手帮忙了.求滚动因为我把marqueen加上去之后.整个层都动了.
前边缺了一大块.要不是少一片marqueen其实也行的. 展开
2个回答
展开全部
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档 </title>
<style type="text/css">
.*{font-size:12px;}
.content {width:900px;margin:0 auto;}
.pic{padding:1px; border:1px solid #B0B0B0; margin:10px auto 0px 13px; float:left;}
.top_left {float:left;}
.new_pic{text-align:center;}
</style>
</head>
<body>
<div class="content box_bor" style="margin-top:0px; height:135px;">
<DIV id=demo style="OVERFLOW: hidden; WIDTH: 900px;">
<TABLE cellSpacing=0 cellPadding=0 align=left border=0 cellspace="0">
<TBODY>
<TR>
<TD id=demo1 vAlign=top><table width="630" height="106" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_01.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_02.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_03.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_04.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_05.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_06.jpg" width="130" height="100" border="0" /></div></td>
</tr>
</table></TD>
<TD id=demo2 vAlign=top> </TD></TR></TBODY></TABLE></DIV>
<script>
var speed3=25//速度数值越大速度越慢
demo2.innerHTML=demo1.innerHTML
function Marquee(){
if(demo2.offsetWidth-demo.scrollLeft<=0)
demo.scrollLeft-=demo1.offsetWidth
else{
demo.scrollLeft++
}
}
var MyMar=setInterval(Marquee,speed3)
demo.onmouseover=function() {clearInterval(MyMar)}
demo.onmouseout=function() {MyMar=setInterval(Marquee,speed3)}
</script>
</div>
</body>
</html>
帮你修改了下,希望对你有所帮助,(*^__^*) 嘻嘻……
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档 </title>
<style type="text/css">
.*{font-size:12px;}
.content {width:900px;margin:0 auto;}
.pic{padding:1px; border:1px solid #B0B0B0; margin:10px auto 0px 13px; float:left;}
.top_left {float:left;}
.new_pic{text-align:center;}
</style>
</head>
<body>
<div class="content box_bor" style="margin-top:0px; height:135px;">
<DIV id=demo style="OVERFLOW: hidden; WIDTH: 900px;">
<TABLE cellSpacing=0 cellPadding=0 align=left border=0 cellspace="0">
<TBODY>
<TR>
<TD id=demo1 vAlign=top><table width="630" height="106" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_01.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_02.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_03.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_04.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_05.jpg" width="130" height="100" border="0" /></div></td>
<td width="130"><div align="center" style="border:solid 1px #CCCCCC; width:136px; height:103px; margin-left:4px; padding-top:3px;"><img src="images/pic_06.jpg" width="130" height="100" border="0" /></div></td>
</tr>
</table></TD>
<TD id=demo2 vAlign=top> </TD></TR></TBODY></TABLE></DIV>
<script>
var speed3=25//速度数值越大速度越慢
demo2.innerHTML=demo1.innerHTML
function Marquee(){
if(demo2.offsetWidth-demo.scrollLeft<=0)
demo.scrollLeft-=demo1.offsetWidth
else{
demo.scrollLeft++
}
}
var MyMar=setInterval(Marquee,speed3)
demo.onmouseover=function() {clearInterval(MyMar)}
demo.onmouseout=function() {MyMar=setInterval(Marquee,speed3)}
</script>
</div>
</body>
</html>
帮你修改了下,希望对你有所帮助,(*^__^*) 嘻嘻……
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
那个要占一个小位置的留一点点位置给他就不会乱了,要不就去搞个JA代码来实现
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询