Web pages try to make life easier for website visitors. There are, however, instances where this is Bad Thing.
Take for example, login pages. Many sites use Javascript to automatically focus the cursor in the 'Username' text box as soon as the page loads. But sometimes, the page loads slowly, and the user may have started typing a username and password even as the rest of the page is loading. The result is that the cursor jumps to the 'Username' text box when the password is being typed - which means that if the user didn't notice, the password (or at least part of it) gets typed in the 'Username' box, in plain view of the nasty folks looking over his shoulder.