By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,865 Members | 1,717 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,865 IT Pros & Developers. It's quick & easy.

-> SCREEN READER DETECTION <-

P: n/a
Hi,

Is it possible to use javascript to detect if a screen reader is
running a on a users machine?

I know that on a pc, screen readers use the MSSA interface. Is there
a way to detect whether this is operational or not?

Thanks,

Ben
Jul 23 '05 #1
Share this Question
Share on Google+
8 Replies


P: n/a
Hi Ben,

As far as I know its probably impossible to detect whether its running
or not, but you could see whether it is installed. The problem is that
you will have to find the class ID (CLSID). This is usually in the
window registry. Open the registry editor ('regedit.exe') and open
HKEY_CLASSES_ROOT

Below all the extentions are lists of objects. Most objects have
classid's (CLSID). For example, Word.Application. You can copy the
classID when you view it.

The following script detects whether word and acrobat are installed on
your computer:

<SCRIPT LANGUAGE="JavaScript">

monitor = new Array();

function checkApplication(clsId, name) {
s = '<object id="test_object'+monitor.length+'" '
+'classid="clsid:'+clsId+'" '
+'codebase="view-source:about:blank">&nbsp;</object>';
document.writeln(s);
monitor[monitor.length] = name;
}

function check() {
for (i=0;i<monitor.length;i++) {
if (monitor[i]!=null) {
obj = document.getElementById('test_object'+i);
if (obj) {
if (obj.readyState!=0) {
alert("'"+monitor[i]+"' is on this machine");
}
monitor[i] = null;
}
}
}
}
checkApplication('000209FF-0000-0000-C000-000000000046',
'Microsoft Word');
checkApplication('B801CA65-A1FC-11D0-85AD-444553540000',
'Acrobat(Reader)');
window.setInterval('check();', 1000);
</SCRIPT>

Well, I hope this helps a bit.

Good luck,
Vincent

Ben Baker wrote:
Hi,

Is it possible to use javascript to detect if a screen reader is
running a on a users machine?

I know that on a pc, screen readers use the MSSA interface. Is there
a way to detect whether this is operational or not?

Thanks,

Ben


Jul 23 '05 #2

P: n/a
ne******@hotmail.com (Ben Baker) wrote in message news:<cb**************************@posting.google. com>...
Hi,

Is it possible to use javascript to detect if a screen reader is
running a on a users machine?

I know that on a pc, screen readers use the MSSA interface. Is there
a way to detect whether this is operational or not?


JavaScript do this cannot without some sort of (most likely insecure)
extension to the browser to access the windows api.

JavaScript can only talk within the browser windows with certain
restictions.

JsD
Jul 23 '05 #3

P: n/a
On 12 Jul 2004 03:24:49 -0700, Ben Baker wrote:
Is it possible to use javascript to detect if a screen reader is
running a on a users machine?


Why? It may sound like a trivial question,
but often when something is not available,
there is some form of strategy you can take
depending on what you want to achieve.

Which leads us to - what do you want to achieve?

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
Jul 23 '05 #4

P: n/a
Hi everyone,

First of all thanks for all of your replies.

What I am trying to achieve is to detect a screen reader's presence, so
that i may load a specific page based on whether it returns true or
false.

Thanks,

Ben ;]

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 23 '05 #5

P: n/a
On 13 Jul 2004 21:01:11 GMT, Ben Baker wrote:
What I am trying to achieve is to detect a screen reader's presence, so
that i may load a specific page based on whether it returns true or
false.


(groans) Specifically *what* will be different
about the specific pages?

Do you have the URLs? An URL for each page
would be most informative, whereas your
response, as it were, ..wasn't.

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
Jul 23 '05 #6

P: n/a
Forgive my insolence Andrew *Shudders in acute embaressment*

THE SCENARIO:

A user is going through a series of HTML pages in a lesson, say ten
pages in total.

By clicking on the 'Next Page' button they are about to leave page 2 and
enter page 3.

However page 3 needs to do a check to see whether there is a screen
reader present. If there is then it will load a text-only version of
the page, else it will load a page with a SWF file in it.

I am aware that accessibility is available in the latest flash player,
but for my purposes this is not an option.

Thanks again,

Ben

:::: YOU CAN'T POLISH TURD. ::::

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 23 '05 #7

P: n/a
On 14 Jul 2004 07:45:47 GMT, Ben Baker wrote:
..page 3 needs to do a check to see whether there is a screen
reader present. If there is then it will load a text-only version of
the page, else it will load a page with a SWF file in it.
So, you are suggesting that there are clients
who have screen readers, yet they have flash
installed? [ No, I am not especially familiar
with this area, so my expectation might be wrong ]
I am aware that accessibility is available in the latest flash player,
but for my purposes this is not an option.


So, it is for people with screen readers installed,
who can use *accessible Flash* (and therefore have it
installed) for which you need this functionality?

[ Ultimately, I think the best, most reliable and
friendliest way to 'detect which page' is using the
'wetware API'.

Present the user with 2 links and describe one as
'Text based' and the other as 'Flash enhanced',
even if the user selects the wrong one, they simply
hit the 'back' button and follow the other.

The problem with a technical solution is that if
it breaks, there is very little the end user can
do to fix it. ]

...and while I remember. Could you refrain from
spelling your subject in capitals in future threads
you start? And especially drop the '->'.. ;-)

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
Jul 23 '05 #8

P: n/a
Hi Andrew,

Thanks for the reply Andrew, that was the conclusion/solution I had come
to; a screen with two links for text only & flash.

I am not quite sure how my thread ended up here as I entered it in
Google groups... however if i post again i will refrain from -> THIS <-

All the best,

Ben ;]
:::: YOU CAN'T POLISH TURD. ::::

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 23 '05 #9

This discussion thread is closed

Replies have been disabled for this discussion.