TEXTAREAs scroll by themselves (on IE8) every time you type one character

Posted by Justin Grant on Stack Overflow See other posts from Stack Overflow or by Justin Grant
Published on 2010-05-29T00:54:14Z Indexed on 2010/05/29 1:12 UTC
Read the original article Hit count: 263

IE8 has a known bug (per connect.microsoft.com) where typing or pasting text into a TEXTAREA element will cause the textarea to scroll by itself. This is hugely annoying and shows up in many community sites, including Wikipedia. The repro is this:

  1. open the HTML below with IE8 (or use any long page on wikipedia which will exhibit the same problem until they fix it)
  2. size the browser full-screen
  3. paste a few pages of text into the TEXTAREA
  4. move the scrollbar to the middle position
  5. now type one character into the textarea

Expected: nothing happens Actual: scrossing happens on its own, and the insertion point ends up near the bottom of the textarea!

Below is repro HTML (can also see this live on the web here: http://en.wikipedia.org/w/index.php?title=Text_box&action=edit)

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<body>
<div style="width: 80%">
<textarea rows="20" cols="80" style="width:100%;" ></textarea>
</div>
</body>
</html>

© Stack Overflow or respective owner

Related posts about css

Related posts about internet-explorer-8