I have this piece of code:
<textarea id="test" style="width: 400px; height: 100px"></textarea>
<script>
var inserting = document.createElement("div");
document.insertBefore(inserting,document.getElementById("test"));
</script>
What should insert DIV id=insertingbefore textarea id=test, but this error occurs
Node was not found" code: "8
I am using FireFox 3.6 with Firebug on WinXP. Where is the problem?
source
share