3

When i try to download the content of websites with special characters like ï, curl returns strange characters. For example when i execute the following from the command line:

curl.exe --GET "http://en.wiktionary.org/wiki/ge%C3%AFnteresseerd"

the (partial) response is:

...wgPageName":"geïnteresseerd","wgTitle":"geïnteresseerd",....

the problem is ï should be ï. Is there anyway to solve this issue? Do i need to re-encode the response?

Nebu
  • 1,753
  • 1
  • 17
  • 33

1 Answers1

4

This is due to handling of unicode characters in a DOS prompt, see Unicode characters in Windows command line - how?. You should be able to change this behavior by using a command like chcp 65001 to set the terminal up for UTF-8 handling.

Community
  • 1
  • 1
Hans Z.
  • 50,496
  • 12
  • 102
  • 115