We’ve just finished building a site that is aimed largely at users with disabilities, and as a result we did quite a bit of testing with the Jaws screen reader to see how the site appears to a blind user.
I got into quite a fight with Jaws, Javascript and bad magic. I was adding some Javascript to modify a Wysiwyg editor to make it a bit more screen-reader friendly. At first it seemed that the Javascript just wasn’t working, but further playing revealed that it was but that Jaws wasn’t seeing the modifications that Javascript had made to the page, which was odd, as Jaws was able to see the Wysiwyg editor which itself had been created by Javascript And sometimes the Javascript just made Jaws read out the text for one link when the keyboard focus was clearly on another.
It turns out that (apparently) Jaws scans the web page when it finishes loading and creates its own copy of the elements on the page, so that when the user tabs through the items on the page Jaws tabs through its own copy of the page and reads out the elements.
Tbe problem is that a lot of Javascript gets run at page load time, (either because the <script> tags have been put at the end of the body, or because there’s some kind of jQuery type $(document).ready() thing in use). And it’s at page load time that Jaws makes its secret copy of your page. So if your Javascript is fast enough then it will run before Jaws reads the page, but if it’s too slow then Jaws wont know about the changes to the page, and so when your user tabs through the items on the page Jaws will read out the item that it thinks is there, even if it’s not.











