[Greasemonkey] getting all of web page into a string

Bill Donnelly donnelly at snowcrest.net
Mon May 1 16:59:53 EDT 2006


I believe you have to do some additional trickery to get
the WHOLE page source. There is code on how to do it in one
of the posts on this list somewhere. Basically, document.body.innerHTML
doesn't get you the stuff in the head and such above the body.
Do a search on the list for "document.body.innerHTML" (Google with
"Greasemonkey") and you should find the post about how to do it.

Anthony Lieuallen wrote:
> On 5/1/2006 2:53 PM, Al wrote:
>> Can you use GM javascript to pull the entire contents of a web page, 
>> on which the script is running, into a string?
>
> From your description, document.body.innerHTML or 
> document.body.textContent should probably do you.  Same thing with 
> reference to head, if you want that part of the page too.
> _______________________________________________
> Greasemonkey mailing list
> Greasemonkey at mozdev.org
> http://mozdev.org/mailman/listinfo/greasemonkey
>

-- 
Nixon wiretapped the DNC offices.  Bush wiretapped the American people.
Bush IS the new Nixon.  And a two-time Sore 'Winner'.  Impeach Bush!

__The United States is NOT "at War!"__
Do not believe their lies and propaganda.  Do not allow them to use this obvious,
blatant excuse against the American people, our freedoms, and our way of life.

Clinton lied and no one died.  pResident Gov. Bush lied and thousands died.
Truly support our troops.  Bring them home!  NOW!



More information about the Greasemonkey mailing list