Re: getting current page content (after DOM mutate)
Ash <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.dom |
|---|---|
| Organization | http://groups.google.com |
| Message-ID | <ffc4e1e4-fd32-48a2-96bd-91221b7096e4@m44g2000hsc.googlegroups.com> |
On Jun 17, 6:52 am, Boris Zbarsky <[email protected]> wrote: > Ash wrote: > > Hmm. All I do is go to the Javascript Shell (part of the Extension > > Developer Extension) and set the scope to browser.xul. I then execute, > > when GMail is the current page: > > window.content.document.body.innerHTML > > > ... and all I get back is serialised HTML that contains a lot of > > inline Javascript .. > > It also contains the <iframe>s that all the "interesting" content is inside. > > > If I explore with the DOM inspector I can indeed see the whole DOM > > layout of my GMail inbox with all the message subjects and dates, etc. > > DOM inspector shows the contents of <iframe>s under the <iframe> in its DOM > tree. See the "#document" node there. > > It sounds like you want to recursively get the innerWhatever of all the > subframes on the page too. > > -Boris Thanks, that was it. I had to do a recursive call with node.contentDocument for any IFRAME - and I';ve got the full text content. Btw, I looked again in the DOM inspector and I couldn't find any mention of an IFRAME in the DOM, I have no doubt they are there but it seems Dom Inspector was handling them transparently (either that or I just didn;t spot them - I even tried a search for tag name tho'). Anyway, thanks. -- Ash