Re: Umlauteproblem

Andreas Jung <[email protected]>
Newsgroups gmane.comp.web.zope.german
Organization ZOPYX Ltd & Co. KG
Message-ID <[email protected]>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 05.02.2009 16:26 Uhr, Ralf Lüdicke wrote:
> Hallo Liste!
> 
> Seit Jahren betreibe ich eine kleine Intranetseite in unserer Firma mit Plone
> und einigen TTW im ZMI geschriebenen Web-Anwendungen als Erweiterungen. In
> unregelmäßigen Abständen mache ich dann eine komplette Migration auf das dann
> jeweils aktuelle Setup. Dies hat bis heute immer ziemlich reibungslos geklappt.
> 
> Derzeit hänge ich aber an dem Update von
> python 2.4.4 / Zope 2.9.8. / Plone 2.5.5
> auf
> python 2.4.5 / Zope 2.10.7 / Plone 3.1.7
> 
> Während die Migration von Plone ohne Problem von statten geht, habe ich mit
> meiner eigenen Anwendung Probleme mit Umlauten. Aber nur, wenn Daten über ein
> Script bearbeitet werden. Alle Umlaute, die über mySQL kommen oder fest
> eingearbeitet sind, werden wie gewünscht dargestellt. Es ist also kein Problem
> der Darstellung im WebBrowser.
> 
> 
> Folgendes Test_Case:
> 
> drei Ordner: folder1 (Titel: Item1), folder2 (Titel: Menü2), folder3 (Titel: Item2)
> 
> Wenn ich nun mit einem python-Script darüber itteriere:
> 
> <code>
> verz=[]
> 
> myObjects = container.objectValues('Folder')
> 
> for item in myObjects:
>   print item.title_or_id(),"\n"
> 
>   verz.append(item.title_or_id())
> 


Du redest oben von Plone und verwendest hier Zope API, die man mit
Plone üblicherweise nicht verwendet. Wie passt das zusammen?

Die Folder sind jetzt was? Plone oder Zope Folder?


> 
> print verz
> 
> return printed
> </code>
> 
> erhalte ich folgendes Ergebnis:
> 
> <result>
> 
> Item1
> 
> Menü2
> 
> Item3
> 
> ['Item1', 'Men\xfc2', 'Item3']
> 
> </result>
> 
> D.h., sobald ich in die Liste schreibe, werden die Umlaute zerhauen.

Wieso wird was zerhauen?
'Men\xfc2' ist perfektes ISO-8859-15.

Beispiel einer interaktiven Python Session:

>>> s='ü'
>>> [s]
['\xfc']


Was ist also Dein wirkliches Problem (ich glaube Du hast keines)?

Andreas

- -- 
ZOPYX Ltd. & Co. KG - Charlottenstr. 37/1 - 72070 Tübingen - Germany
Web: www.zopyx.com - Email: [email protected] - Phone +49 - 7071 - 793376
Registergericht: Amtsgericht Stuttgart, Handelsregister A 381535
Geschäftsführer/Gesellschafter: ZOPYX Limited, Birmingham, UK
- ------------------------------------------------------------------------
E-Publishing, Python, Zope & Plone development, Consulting

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkmLEVoACgkQCJIWIbr9KYyteACfW+8aLEDfILL5U9uPbqJMa+Yp
BlgAoLnaVlxIVnaoAnBoi1pw4QebTQVZ
=gcbJ
-----END PGP SIGNATURE-----



_______________________________________________
zope mailing list
[email protected]
https://mail.dzug.org/mailman/listinfo/zope
lists.vcf (text/x-vcard, 316 B)
begin:vcard
fn:Andreas Jung
n:Jung;Andreas
org:ZOPYX Ltd. & Co. KG
adr;quoted-printable:;;Charlottenstr. 37/1;T=C3=BCbingen;;72070;Germany
email;internet:[email protected]
title:CEO
tel;work:+49-7071-793376
tel;fax:+49-7071-7936840
tel;home:+49-7071-793257
x-mozilla-html:FALSE
url:www.zopyx.com
version:2.1
end:vcard
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.