Js-dom: scrollleft scrolling of the base---fixed area

Source: Internet
Author: User

<style type= "Text/css" >
#wrap {
height:200px;
width:200px;
border:5px solid yellow;
Overflow:hidden;
}
#child {
height:500px;
width:500px;
Background-color: #ccc;
}
</style>

<script>

Window.onload=function () {

Owrap=document.getelementbyid ("wrap");

var start=0;

var timer=setinterval (function () {

start++;

if (start>=200) {

Clearinterval (timer);

}

Owrap.scrollleft=start;

},30);

}

</script>

<div id= "Wrap" >
<div id= "Child" > The occurrence of a flying real score scatter the occurrence of a fly-by-the-fly-score scatter of the occurrence of the flying real score scatter the occurrence of the occurrence of the happening of the water and electricity of the spread of the actual score scatter flying real scores scatter the occurrence of the fly-out score scatter the occurrence of the flying real scores of the occurrences of the flying real scores sprinkled the occurrence of the occurrence of the FEI real score scatter the occurrence of the fly The real score scatter the occurrence of the flying real score of the occurrence of the fly who happened to the occurrence of the water and electricity charge of the spread of the actual score scatter the occurrence of the flying real score scattered the occurrence of the flying real score scattered the occurrence of the fly-out of the occurrence of a flying man who happened the occurrence of the water bill </div>
</div>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.