[Project_owners] DOM Element Contents

Nathan R. Yergler nathan at yergler.net
Tue Feb 10 13:05:49 EST 2004

I'm working on a problem right now where I want to extract some of the 
current document's markup as a string.  The 
document.documentElement.innerHTML method works for HTML documents, but 
when working with SVG it's undefined.  I can get a handle to an Element 
object, but not HTMLElement (where it appears the innerHTML method is 
defined).  Any suggestions for retrieving the contents of an Element as 
a string?  Thanks.

Nathan R. Yergler

More information about the Project_owners mailing list