Not logged in. · Lost password · Register
Forum: agsXMPP RSS
Avatar
hexin #1
User title: to search knowledge
Member since Mar 2007 · 34 posts · Location: China
Group memberships: Members
Show profile · Link to this post
Subject: two problem about miniclient
1  When the message I send are Chinese characters, the message receiver receives sometimes contain some unrecognizable characters   like this '???'.Why does this happen ? When the body of message are all English characters,this phenomena doesn't happen. Is it because that the property m_ClientLanguage of class XmppClientConnection  is set to 'en'?

2 when i send long message, the miniclient will auto disconnetct from server. I have no idea what leads to this phenomena. When i use spark client, this doesn't happpen.
Avatar
Alex #2
Member since Feb 2003 · 4317 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Quote by hexin:
1  When the message I send are Chinese characters, the message receiver receives sometimes contain some unrecognizable characters   like this '???'.Why does this happen ? When the body of message are all English characters,this phenomena doesn't happen. Is it because that the property m_ClientLanguage of class XmppClientConnection  is set to 'en'?
no, this is not related to the language attribute. XMPP streams are UTF-8 encoded, which means there should be no problem at all with Chinese characters because UTF-8 can encode characters up to 4 bytes/chars.
Is the string of your message unicode?
Do all your UI controls support full unicode?

Quote by hexin:
2 when i send long message, the miniclient will auto disconnetct from server. I have no idea what leads to this phenomena. When i use spark client, this doesn't happpen.
How long is your message? Some server have a max stanza size setting and will disconnect you when you exceed this limit. Can you attach a XML log?

Alex
Avatar
hexin #3
User title: to search knowledge
Member since Mar 2007 · 34 posts · Location: China
Group memberships: Members
Show profile · Link to this post
1    How can I test if the string of my message is unicode? My develope environment is vs 2005. We rewrite the RichTextBox control of VS 2005 to support inserting link and image. we get message content like this: message.body=richtextbox.Text. This phenomena appears after we upgrade the openfire server to version 3.4.0. The previos version didn't happen. I think it is  the bug of openfire server.But this phenomena didn't happen in spark client .

2  The second phonemena  also only happen after I upgrade openfire to version 3.4.2,and it happens sometimes ,not always. And when happens,I send a short message, and after this operation, if I send long message, this phenomena doesn't happen again.
Avatar
Alex #4
Member since Feb 2003 · 4317 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
.NET handles all strings as unicode internal. So you should be OK when using the Richtextbox.
We have changed nothing in our XML parser and writer related to utf-8 and unicode. If it worked before with an older Openfire version then there must be a bug in the new Openfire version which you are using.

Downgrade your server or contact Jive Software for Openfire support.

Alex
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Forum: agsXMPP RSS