vb.net http波兰语语言的数据混乱了 [英] vb.net http post data in polish language messed up

查看:120
本文介绍了vb.net http波兰语语言的数据混乱了的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Encoding.UTF8.GetBytes(postData)将我的波兰语内容发布到我的网站数据库中.但是,当我在cpanel phpmyadmin中打开文本时,会看到不同的内容(我说不一样,因为我看到了大量的垃圾东西).

您在PC端看到,我能够使用RichTextBoxStreamType.UnicodePlainText读写波兰语的内容.我打开时的文本文件与读取的文件具有相同的内容.

但是在服务器上,我不知道发生了什么变化. UTF8不是unicode格式吗?我需要做些其他事情来加载和读取在线页面上的波兰语内容吗?

问候,

Hi iam using Encoding.UTF8.GetBytes(postData) to post my polish language content to my website database. But when i open the text in cpanel phpmyadmin i see different content (i say different because i see tonnes of garbage things).

You see on pc side i am able to read and write polish content using a RichTextBoxStreamType.UnicodePlainText. The text file while i open has same content as the file read.

But on server i don''t know what changes. Isn''t UTF8 a unicode format? Do i have to do something different to load and read polish content from online pages?

Regards,

推荐答案

UTF只是Unicode UTF之一,在大多数情况下是最实用的之一,并且是Internet和其他用途的标准分解因子.所有UTF代表所有Unicode代码点的100%,并且具有一对一的对应关系,但并非无关紧要的对应关系.在Windows中,内存中Unicode字符串的表示形式为UTF-16LE.当然,如果您假设另一个UTF来解释一个UTF,那么您将完全搞砸了.

关于UTF,请参阅:
http://en.wikipedia.org/wiki/Unicode [ http://www.unicode.org [ ^ ],
http://www.unicode.org/faq/utf_bom.html [ http://en.wikipedia.org/wiki/Unicode [ https://en.wikipedia.org/wiki/Rich_Text_Format#Character_encoding [ http://www.zopatista.com/python/2012/06/06/rtf -and-unicode/ [ ^ ].

从您的问题来看,不清楚您的角色是如何被弄乱的,因为您没有显示代码并描述了步骤,但这很有可能.解决问题的方法也一样:可能,但要取决于完成的工作.我认为如果您学习文档并撤退自己的步骤,您可以自己完成.

尽管Microsoft平台和库广泛支持RTF,但您应该了解这是一种专有格式,几乎已经过时了.从Internet和WWW标准的角度来看,使用它……好吧,不能认为它是严肃的事情.

—SA
UTF is just one of Unicode UTFs, one of the most practical one''s in most cases, and standard de-factor for Internet and other uses. All UTFs represent 100% of all Unicode code point and have one-to-one correspondence but not trivial one. In Windows, presentation of Unicode stings in memory is UTF-16LE. Of course, if your try to interpret one UTF assuming this is some other UTF, you will totally mess up things.

On UTFs, please see:
http://en.wikipedia.org/wiki/Unicode[^],
http://www.unicode.org[^],
http://www.unicode.org/faq/utf_bom.html[^],
http://en.wikipedia.org/wiki/Unicode[^].

As to RTF, the presentation of Unicode in is it somewhat messed up. This is because RTF was created before Unicode was introduced. You can find further detain here:
https://en.wikipedia.org/wiki/Rich_Text_Format#Character_encoding[^].

See also:
http://www.zopatista.com/python/2012/06/06/rtf-and-unicode/[^].

From your question, is not clear how your character messed up, because you did not show your code and described the steps, but it''s very likely. Same thing about the ways to untangle the problem: it is possible but depends on what was done. I think you can do it by yourself you if learn documentation and retreat your steps.

Despite of wide support of RTF on Microsoft platforms and libraries, you should understand that this is a proprietary format, and pretty much obsolete one. From the standpoint of Internet and WWW standards, using it… well, it cannot be considered as something serious.

—SA


这篇关于vb.net http波兰语语言的数据混乱了的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆