このようなDIVセットアップがあります。
<div id="parent" class="parent">
<div id="child" class="child">
</div>
</div>
スタイル
<style>
.parent{
float:left; height:300; width:300px; background-color:#00ff00;
}
.child{
float:left; height:60; width:60px; background-color:#00ff00;
}
</style>
<script>
function move(){
while(m < 100){
document.getElementByid('child').style.marginTop = m;
m = m+1;
}
}
move();
</script>
内側の DIV (名前付きの子) をピクセルごとに上から下に 100 ピクセルずつ移動したいと考えています。style.marginTop = '' と settimeout() 関数を使用して実行できると思います
しかし、まだこれを機能させることができません。