[jawsscripts] Re: DOM Structure

Hi,

I get the same results. But I found that I can use following
let dom = IEGetUnrestrictedWindow (IEGetCurrentDocument ())
let htmlString = dom.documentElement.InnerHtml ()
; innerHTML instead of outerHTML

IEGetUnrestrictedWindow gives document.top object.  Sometimes You get only 
one frame with
IEGetCurrentDocument.

at least  In JAWS versions 5 or 6 or 7 was so.
May be something is changed in the meantime.


Artur
----- Original Message ----- 
From: "Bryan Garaventa" <bgaraventa11@xxxxxxxxxxxxxx>
To: <jawsscripts@xxxxxxxxxxxxx>
Sent: Friday, June 20, 2008 10:41 PM
Subject: [jawsscripts] Re: DOM Structure


Is the DOM that is returned different from a standard document object using
this function? I'm not getting reliable results, for instance,

Script tmpScript ()

Say ("test", 0)

var object dom, string htmlString

; Works:

;let dom = IEGetCurrentDocument ()

; Does not work:

let dom = IEGetUnrestrictedWindow (IEGetCurrentDocument ())

; Save the entire contents of the DOM into a string.

let htmlString = dom.documentElement.outerHtml

CopyToClipboard (htmlString)

Say (htmlString, 0)

EndScript



----- Original Message ----- 
From: "Artur Räpp" <rtr@xxxxxxxxx>
To: <jawsscripts@xxxxxxxxxxxxx>
Sent: Friday, June 20, 2008 8:21 AM
Subject: [jawsscripts] Re: DOM Structure


> Hi,
>
> Try something similar
>
> Script test3 ()
>
> var
>
> object allIE,
>
> object frame1
>
> let allIE = IEGetUnrestrictedWindow (IEGetCurrentDocument ())
>
> let frame1 = allIE.frames("index")
>
> ; get frame named index
>
> saystring (frame1.name) ; jaws says index
>
> EndScript
>
>
>
> hth
>
> Artur
>
> ----- Original Message ----- 
> From: "don mauck" <don.mauck@xxxxxxxxxx>
> To: <jawsscripts@xxxxxxxxxxxxx>
> Sent: Friday, June 20, 2008 4:25 PM
> Subject: [jawsscripts] Re: DOM Structure
>
>
> Yes, I would be very interested in seeing that, I tried
> IEGetUnrestrictedWi=
> ndow but could not see a way to get the frame I needed, it would sure be
> in=
> teresting to see if it could be done.   These scripts I'm doing will be
> use=
> d by many people.  =
>
>
>
>
> Oracle
> Don Mauck | Accessibility Evangelist =
>
> Cross Applications Unlimited
> 7700 Technology Way
> Denver CO 80237
> Phone (303) 334-4184
> Email don.mauck@xxxxxxxxxx =
>
>
> -----Original Message-----
> From: jawsscripts-bounce@xxxxxxxxxxxxx
> [mailto:jawsscripts-bounce@freelists=
> .org] On Behalf Of Bryan Garaventa
> Sent: Friday, June 20, 2008 1:57 AM
> To: jawsscripts@xxxxxxxxxxxxx
> Subject: [jawsscripts] Re: DOM Structure
>
> I've never seen this work before. Can you show an example of the correct
> sy=
> ntax to retrieve the document object for the second frame in a parent
> Frame=
> Set document? For instance, if the content of the second FrameSet document
> =
> currently has focus such as by tabbing or reading within JAWS. That would
> h=
> elp a lot.
>
> Thanks,
>
> Bryan
>
> ----- Original Message -----
> From: "Artur R=E4pp" <rtr@xxxxxxxxx>
> To: <jawsscripts@xxxxxxxxxxxxx>
> Sent: Thursday, June 19, 2008 10:30 PM
> Subject: [jawsscripts] Re: DOM Structure
>
>
>> Hi,
>>
>> You can use IEGetUnrestrictedWindow for frames instead of =
>
>> IEGetCurrentDocument.
>>
>> HTH
>> Artur
>> ----- Original Message -----
>> From: "don mauck" <don.mauck@xxxxxxxxxx>
>> To: <jawsscripts@xxxxxxxxxxxxx>
>> Sent: Thursday, June 19, 2008 7:27 PM
>> Subject: [jawsscripts] Re: DOM Structure
>>
>>
>> Hello again,
>> I've been looking at the HTML code this is brining in and I note that =
>
>> not a=3D ll the source code is here.  That is when I do a views of the =
>
>> source I see =3D much more than I am seeing from the DOM.  Is there a =
>
>> way to get all of the =3D source into the DOM?  It appears that there is
>> =
> =
>
>> more than on frame, would th=3D at make a difference, can I control =
>
>> which frame I am pulling the DOM source=3D to of?  Thanks again for all =
>
>> the great advice. =3D
>>
>>
>>
>>
>> Oracle
>> Don Mauck | Accessibility Evangelist =3D
>>
>> Cross Applications Unlimited
>> 7700 Technology Way
>> Denver CO 80237
>> Phone (303) 334-4184
>> Email don.mauck@xxxxxxxxxx =3D
>>
>>
>> -----Original Message-----
>> From: jawsscripts-bounce@xxxxxxxxxxxxx
>> [mailto:jawsscripts-bounce@freelists=3D
>> .org] On Behalf Of Bryan Garaventa
>> Sent: Wednesday, June 18, 2008 10:54 AM
>> To: jawsscripts@xxxxxxxxxxxxx
>> Subject: [jawsscripts] Re: DOM Structure
>>
>> The best way is to save the DOM to a variable like so,
>>
>> var object dom, string htmlString
>>
>> let dom =3D3D IEGetCurrentDocument()
>>
>> ; Save the entire contents of the DOM into a string.
>>
>> let htmlString =3D3D dom.documentElement.outerHTML
>>
>> Say (htmlString, 0)
>>
>>
>> Just use standard JavaScript commands to access more specific elements
>> with=3D
>> in the DOM. Like...
>>
>> let NumberOfFrames =3D3D dom.frames.length
>>
>> And so on.
>>
>>
>> ----- Original Message -----
>> From: "don mauck" <don.mauck@xxxxxxxxxx>
>> To: <jawsscripts@xxxxxxxxxxxxx>
>> Sent: Wednesday, June 18, 2008 9:28 AM
>> Subject: [jawsscripts] DOM Structure
>>
>>
>>>I know this question might have been answered at some earlier time, =3D
>>
>>>however, I admit I cannot find any of the responses.  I need to examine
>>>=3D=
>
>>
>>>the values in a DOM structure so I'm thinking tat I could load it into
>>>=3D=
>
>>
>>>a string and then evaluate it from their.  I just don't find anything
>>>=3D=
>
>>
>>>in the "Default.JSS" or anywhere else that strings information directly
>>>=3D=
>
>>
>>>from the DOM.  Can anyone on this list refresh my memory or give me =3D
>>
>>>some pointer/ideas?  I promise I won't delete or otherwise lose the =3D
>>
>>>responses so as not to bother the list again with this question.  Thanks
>>>i=3D
>> n advance.
>>>
>>> Oracle <http://www.oracle.com/>
>>> Don Mauck | Accessibility Evangelist
>>> Cross Applications Unlimited
>>> 7700 Technology Way
>>> Denver CO 80237
>>> Phone (303) 334-4184
>>> Email don.mauck@xxxxxxxxxx
>>>
>>>
>>> __________
>>> View the list's information and change your settings at =3D
>>
>>> http://www.freelists.org/list/jawsscripts
>>>
>>
>> __________
>> View the list's information and change your settings at
>> http://www.freelist=3D
>> s.org/list/jawsscripts
>>
>>
>> __________
>> View the list's information and change your settings at
>> http://www.freelists.org/list/jawsscripts
>>
>>
>>
>> __________
>> View the list's information and change your settings at
>> http://www.freelists.org/list/jawsscripts
>>
>
> __________=A0
> View the list's information and change your settings at
> http://www.freelists.org/list/jawsscripts
>
>
> __________
> View the list's information and change your settings at
> http://www.freelists.org/list/jawsscripts
>
>
>
> __________
> View the list's information and change your settings at
> http://www.freelists.org/list/jawsscripts
>

__________
View the list's information and change your settings at
http://www.freelists.org/list/jawsscripts



__________ 
View the list's information and change your settings at 
http://www.freelists.org/list/jawsscripts

Other related posts: