blob: 9357342bfb8e2d6bcc546334d132013961db691c [file] [log] [blame]
<script>
function test()
{
if (window.testRunner)
testRunner.dumpAsText();
var ta = document.getElementById("ta");
ta.focus();
document.execCommand("InsertLineBreak");
var result = ta.value;
if (result == "\n")
document.write("<p>Hooray, the test was successful!</p>");
else
document.write("<p>The test failed, result was '" + result.replace("\n", "\\n") + "'.</p>");
}
</script>
<body onload="test()">
<p><textarea id="ta"></textarea></p>