Тема: AHK: Скачивание в определенной кодировке
Как скачать страницу в корректной кодировке, чтобы слово «Stihotvoreniâ» отображалось, как на сайте — «Stihotvoreniâ»?
HTTP := ComObjCreate("WinHTTP.WinHTTPRequest.5.1")
HTTP.Open("GET", "https://polona.pl/api/entities/MTE5NzAzNTE3/?add_history_event=true", true)
HTTP.SetRequestHeader("User-Agent", "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.79 Safari/537.36")
HTTP.SetRequestHeader("Pragma", "no-cache")
HTTP.SetRequestHeader("Cache-Control", "no-cache, no-store")
HTTP.SetRequestHeader("If-Modified-Since", "Sat, 1 Jan 2000 00:00:00 GMT")
HTTP.Send()
HTTP.WaitForResponse()
MsgBox % HTTP.ResponseText