Answer the question
In order to leave comments, you need to log in
How to fix an error in Ruby when Uri.parse () when there is a Russian word inside it?
For example, I want to parse a link
https://geocode-maps.yandex.ru/1.x/?geocode=Тверская+6
url = URI.parse("https://geocode-maps.yandex.ru/1.x/?geocode=Тверская+6")
URI::InvalidURIError: URI must be ascii only "https://geocode-maps.yandex.ru/1.x/?geocode=\u{422}\u{432}\u{435}\u{440}\u{441}\u{43a}\u{430}\u{44f}+6"
Answer the question
In order to leave comments, you need to log in
I didn’t touch Rubi when, but in other languages there are constructions similar to urlencode.
You may need to google in that direction.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question