User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1a1pre) Gecko/2008060403 Minefield/3.1a1pre
Maxlength is not respected when value of the text input changes dynamically with javascript. Firefox 2 behaves as expected and the value is truncated.
<input type="text" maxlength="5" id="test" />
<script language="JavaScript">
document.getElementById('test').value = "longer than it should be";
</script>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1a1pre) Gecko/2008060403 Minefield/3.1a1pre
Maxlength is not respected when value of the text input changes dynamically with javascript. Firefox 2 behaves as expected and the value is truncated.
<input type="text" maxlength="5" id="test" /> "JavaScript" > getElementById( 'test') .value = "longer than it should be";
<script language=
document.
</script>
Reproducible: Always
Steps to Reproduce:
1.
2.
3.