logo       

Re: import html in a document: msg#00128

java.enhydra.xmlc

Subject: Re: import html in a document


You are close, but you need to remember that nodes from two different documents don't know about each other until you import them into the current document you are working on. Try this...

aHTML.getElementContentTarget().appendChild(aHTML.importNode(bHTML.getElementContentSource(), true));

I'm pretty sure you can do all that in one line, but you'll have to try it out to make sure.


Jake

At 01:40 PM 9/22/2003 +0200, you wrote:
Hi,

I have one question. Let's say there are two HTML files:

a.html
----------

b.html
-----------

text

Is it possible to include the whole content from the div tag with the id
"contentSorce" in b.html into the div tag with the id "contentTarget" in
a.html?
I tried
aHTML.getElementContentTarget().appendChild(bHTML.getElementContentSource())
but it doesn't work.

Thanks
Thorsten



_______________________________________________
XMLC mailing list
XMLC@xxxxxxxxxxx
http://www.enhydra.org/mailman/listinfo.cgi/xmlc


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise