cyrillic

Unable to print russian characters

落花浮王杯 提交于 2019-11-27 23:53:51
I have a russian string which i have encoded to UTF-8 String str = "\u041E\u041A"; System.out.println("String str : " + str); When i print the string in eclipse console i get ?? Can anyone suggest how to print the russian strings to console or what i am doing wrong here? I have tried converting it to bytes using byte myArr[] = str.getBytes("UTF-8") and then new String(myArr, "UTF-8") still same problem :-( Try this: String myString = "some cyrillic text"; byte bytes[] = myString.getBytes("ISO-8859-1"); String value = new String(bytes, "UTF-8"); Or this: String myString = "some cyrillic text";

regexp with russian lang

我的梦境 提交于 2019-11-27 13:21:37
I can't solve my problem with regexp. Ok, when i type: $string = preg_replace("#\[name=([a-zA-Z0-9 .-]+)*]#","$name_start $1 $name_end",$string); everything is ok, except situation with Russian language. so, i try to re-type this reg-exp: $string = preg_replace("#\[name=([a-zA-Z0-9**а-яА-Я** .-]+)*]#","$name_start $1 $name_end",$string); but this not working, i know some idea, just write: $string = preg_replace("#\[name=([a-zA-Z0-9йцукенгшщзхъфывапролджэячсмитьбю .-]+)*]#","$name_start $1 $name_end",$string); but this is crazy :D please, give me simple variant Try a Unicode range: '/[\x{0410}-

VBA - Convert string to UNICODE

时间秒杀一切 提交于 2019-11-27 09:10:03
I need to convert the string HTML from a mix of Cyrillic and Latin symbols to UNICODE. I tried the following: Public HTML As String Sub HTMLsearch() GetHTML ("http://nfs.mobile.bg/pcgi/mobile.cgi?act=3&slink=6jkjov&f1=1") MsgBox HTML HTML = StrConv(HTML, vbUnicode) MsgBox HTML End Sub Function GetHTML(URL As String) As String With CreateObject("MSXML2.XMLHTTP") .Open "GET", URL, False .Send HTML = .ResponseText End With End Function You can see what is before and after the StrConv. If you like to get the html in a file, you can use the following code: Public HTML As String Sub HTMLsearch()

regexp with russian lang

ε祈祈猫儿з 提交于 2019-11-26 22:23:02
问题 I can't solve my problem with regexp. Ok, when i type: $string = preg_replace("#\[name=([a-zA-Z0-9 .-]+)*]#","$name_start $1 $name_end",$string); everything is ok, except situation with Russian language. so, i try to re-type this reg-exp: $string = preg_replace("#\[name=([a-zA-Z0-9**а-яА-Я** .-]+)*]#","$name_start $1 $name_end",$string); but this not working, i know some idea, just write: $string = preg_replace("#\[name=([a-zA-Z0-9йцукенгшщзхъфывапролджэячсмитьбю .-]+)*]#","$name_start $1

VBA - Convert string to UNICODE

大憨熊 提交于 2019-11-26 17:48:35
问题 I need to convert the string HTML from a mix of Cyrillic and Latin symbols to UNICODE. I tried the following: Public HTML As String Sub HTMLsearch() GetHTML ("http://nfs.mobile.bg/pcgi/mobile.cgi?act=3&slink=6jkjov&f1=1") MsgBox HTML HTML = StrConv(HTML, vbUnicode) MsgBox HTML End Sub Function GetHTML(URL As String) As String With CreateObject("MSXML2.XMLHTTP") .Open "GET", URL, False .Send HTML = .ResponseText End With End Function You can see what is before and after the StrConv. If you