german umlaute
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- Posts: 38
- Joined: Mon Jan 03, 2011 5:42 pm
- Location: Switzerland, Burgdorf
german umlaute
Is it realiy true? does runrev not work with german umlauts? I have in a Database german words as "Schriftart wählen" etc. When I read this records in a runrev query I get "Schriftart wählen". Any help? Thank you.
Fredi
Fredi
-
- VIP Livecode Opensource Backer
- Posts: 9648
- Joined: Wed May 06, 2009 2:28 pm
- Location: New York, NY
Re: german umlaute
I am probably out of my depth, but ASCII 159 and unicode 00FC both produce this character.
Craig Newman
Craig Newman
Re: german umlaute
Hi Fred,
what encoding is being used in your database?
I guess that internally all text will be treated a ISO, so on the Mac you will see this inconvenience!
Try to convert your text to iso
-> mactosio("your text here") BEFORE writing to the database and convert back
-> isotomac(...) after you retrieved data from the database and BEFORE you put this into any field.
Something like this:
Best
Klaus
Best
Klaus
what encoding is being used in your database?
I guess that internally all text will be treated a ISO, so on the Mac you will see this inconvenience!
Try to convert your text to iso
-> mactosio("your text here") BEFORE writing to the database and convert back
-> isotomac(...) after you retrieved data from the database and BEFORE you put this into any field.
Something like this:
Code: Select all
...
if the platform = "MacOS" then
put mactoiso(...)...
end if
...
Klaus
Best
Klaus
-
- VIP Livecode Opensource Backer
- Posts: 1236
- Joined: Sat Apr 08, 2006 1:10 pm
- Location: Zurich
- Contact:
Re: german umlaute
looks more like utf8 to me. try these two functions at the appropriate places:
Code: Select all
function createUtf8Text theText
return unidecode(uniencode(theText),"utf8")
end createUtf8Text
function getRevTextFromUTF8 theText
return unidecode(uniencode(theText,"utf8"))
end getRevTextFromUTF8
Various teststacks and stuff:
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
-
- Posts: 38
- Joined: Mon Jan 03, 2011 5:42 pm
- Location: Switzerland, Burgdorf
Re: german umlaute
Thank you to all, i will try and report it.
-
- Posts: 38
- Joined: Mon Jan 03, 2011 5:42 pm
- Location: Switzerland, Burgdorf
Re: german umlaute
Hi BvG
Your function does work:
function getRevTextFromUTF8 theText
return unidecode(uniencode(theText,"utf8"))
end getRevTextFromUTF8
but only without the 8 in the function-name.
THANK YOU
Your function does work:
function getRevTextFromUTF8 theText
return unidecode(uniencode(theText,"utf8"))
end getRevTextFromUTF8
but only without the 8 in the function-name.
THANK YOU
-
- Posts: 38
- Joined: Mon Jan 03, 2011 5:42 pm
- Location: Switzerland, Burgdorf
Re: german umlaute
Hi there
Now I have a new problem like this - i work now with mac
When I save a string like this "Wir gehen in der Küche Brot holen" in a sqllite database, then the string is after the umlaut ü broken. In the database is only saved "Wir gehen in der K". Thanks for any help.
Fredi
Now I have a new problem like this - i work now with mac
When I save a string like this "Wir gehen in der Küche Brot holen" in a sqllite database, then the string is after the umlaut ü broken. In the database is only saved "Wir gehen in der K". Thanks for any help.
Fredi
-
- Posts: 38
- Joined: Mon Jan 03, 2011 5:42 pm
- Location: Switzerland, Burgdorf
Re: german umlaute
I found it: because I work now with mac it is: put ISOtoMac(tTextzeile1) into tTextzeile1
Thanks all Readers
Thanks all Readers