On Tuesday 01 July 2003 21:15, you wrote: > How do I create leading tag > > <?xml version="1.0"?> > > in an XML document (or make such tag visible in return from "domDoc > asXML" command)? Rest of my document is nested element and text nodes. >
My collegue Rolf writes: tDOM doesn't do that for you, you do that (if you need one). The reason for this is, that tDOM could not know, which encoding you use, to write the serialized XML. If you write with encoding utf-8, there is no need for an XML declaration - the document is wellformed and in absent of an XML declaration, the parser assumes the document, to be encoded in UTF-8, which is just right. If you use another encoding, to write the serialized XML, you have to provide your own XML declaration (with the appropriate encoding info) anyway. Just do puts $outfd "<?xml version="1.0" encoding="..."?> puts $outfd [$doc asXML] BTW, for all of you interested, there is a tdom mailing list on [EMAIL PROTECTED] tdom developers monitor this list. Cheers, Zoran > Thanks - Alex > > > -- > AOLserver - http://www.aolserver.com/ > > To Remove yourself from this list, simply send an email to > <[EMAIL PROTECTED]> with the body of "SIGNOFF AOLSERVER" in the > email message. You can leave the Subject: field of your email blank. -- AOLserver - http://www.aolserver.com/ To Remove yourself from this list, simply send an email to <[EMAIL PROTECTED]> with the body of "SIGNOFF AOLSERVER" in the email message. You can leave the Subject: field of your email blank.