在图片的点击事件里,控制对象的scrollTop 和 scrollLeft属性就可以了.

解决方案 »

  1.   

    <body onload="document.getElementById('ice').stop()">
    <div style="float:left;width:100px;background:#F00;height:100px;margin-right:10px;" onmouseover="document.getElementById('ice').start()" onmouseout="document.getElementById('ice').stop()">
    移过来
    </div>
    <marquee id="ice" style="float:left;width:200px;height:100px;border:1px solid #000" behavior="scroll" direction="up">
    我想用一个小图片来控制旁边的一段内容的上下滚动,上鼠标移到这个图片上时,旁边的内容就向上或者向下滚动。
    请高手指教~
    </marquee>
    </body>
      

  2.   

    <body onload="document.getElementById('ice').stop()">
    <div style="float:left;width:100px;background:#F00;height:100px;margin-right:10px;" onmouseover="document.getElementById('demo').start()" onmouseout="document.getElementById('demo').stop()">
    移过来
    </div>
    <marquee id="demo" style="float:left;width:100px;height:100px;border:1px solid #000" behavior="scroll" direction="up" scrollamount =1 >
    56756</marquee>
    </body>
      

  3.   

    <body onload="document.getElementById('ice').stop()">
    <div style="float:left;width:100px;background:#F00;height:100px;margin-right:10px;" onmouseover="ice.direction='up';document.getElementById('ice').start()" onmouseout="document.getElementById('ice').stop()">
    向上~
    </div>
    <marquee id="ice" style="float:left;width:200px;height:100px;border:1px solid #000" behavior="scroll">
    我想用一个小图片来控制旁边的一段内容的上下滚动,上鼠标移到这个图片上时,旁边的内容就向上或者向下滚动。
    请高手指教~
    </marquee>
    <div style="float:left;width:100px;background:#F00;height:100px;margin-right:10px;" onmouseover="ice.direction='down';document.getElementById('ice').start()" onmouseout="document.getElementById('ice').stop()">
    向下~
    </div>
    </body>