From: Daniel Veillard (Daniel.Veillard@w3.org)
Date: Tue Aug 29 2000 - 13:36:05 EDT
On Tue, Aug 29, 2000 at 06:04:12PM +0200, Stefan Bambach wrote:
>
> Hi,
>
> I wrote a basic libxml wrapper for python (very basic :-) ). I walk
> through the DOM tree by myself (child = child->next) and read out the
> content. I had access to the TAGs and the values, attributes, ... .
>
> Now with libxml 2.2.2 the DOM tree's content is UTF8 encoded and can't
> read out it as simple as it was before. I have to convert the values
> to ISO-8859-1.
Or EUC-JP if you're japanese or ISO-8859-2 if you're russian, etc ...
Yes libxml is now consistant independantly of the kind of input.
> Is there a Funktion that is equivalent to some kind of ugly code like
> printf ('%s', node->name) doing the encoding, too ?
question is what encoding .... Are you just interested in ISO-8859-1 ?
If the answer is yes it's a good idea to ask you the question: why ?
> Are there functions to read out the content (value) of a tag, the tag
> itself and attribute names with there value ?
Do you mean that python has no support for handling UTF8 strings ???
How is python expected to work in Internationalized environments ?
Converting the value as you read them from the tree content may not
make much sense, I would expect high level languages like python to
be able to work out of the box with UTF8 strings, I am very surprized.
Daniel
-- Daniel.Veillard@w3.org | W3C, INRIA Rhone-Alpes | Today's Bookmarks : Tel : +33 476 615 257 | 655, avenue de l'Europe | Linux XML libxml WWW Fax : +33 476 615 207 | 38330 Montbonnot FRANCE | Gnome rpm2html rpmfind http://www.w3.org/People/all#veillard%40w3.org | RPM badminton Kaffe ---- Message from the list xml@xmlsoft.org Archived at : http://xmlsoft.org/messages/ to unsubscribe: echo "unsubscribe xml" | mail majordomo@xmlsoft.org
This archive was generated by hypermail 2b29 : Tue Aug 29 2000 - 10:43:18 EDT