<!DOCTYPE html> | |
<html> | |
<head> | |
<script> | |
function performTest() | |
{ | |
var ps = document.getElementsByTagName("P"); | |
var pos1 = new Position(ps[0],0); | |
var pos2 = new Position(ps[0],2); | |
Position_trackWhileExecuting([pos1,pos2],function() { | |
insertAtPosition(pos1,DOM_createElement(document,"b")); | |
insertAtPosition(pos2,DOM_createElement(document,"i")); | |
}); | |
} | |
</script> | |
</head> | |
<body><p><span>Zero</span><span>One</span></p><p>Two</p><p>Three</p></body></html> |