нет, вы ошибаетесь
<!DOCTYPE HTML>
<html>
<head> </head>
<body>
<div id='wrapper'>
<div>1 </div>
<div> 2</div>
<div>3 </div>
</div>
<script>
var wrapper_ = document.getElementById('wrapper');
var elem = wrapper_.children[1];
alert(wrapper_.children[3] == null);//wrapper_.children[3] == undefined, a undefined == null
wrapper_.insertBefore(elem, wrapper_.children[3])
</script>
</body>
</html>
|