Reputation:
I have the following string:
Ruby :: \u041D\u043E\u0432\u0438\u043D\u0438
My question is how to convert it to utf8 characters (in my case cyrilic letters)?
Upvotes: 2
Views: 7298
Reputation: 11494
In Ruby 1.9:
"\u041D\u043E\u0432\u0438\u043D\u0438".encode("UTF-8")
=> "Новини"
Upvotes: 8