Verified Commit ed4c95e9 authored by Artem Klevtsov's avatar Artem Klevtsov 😹

Fix example with curl

parent 21c9fa7a
Pipeline #101353081 passed with stages
in 9 minutes and 30 seconds
......@@ -41,11 +41,11 @@ ced_enc_detect(iconv(ex_txt[["Japanese"]], "utf8", "iso-2022-jp"))
\donttest{
# detect encoding of the web pages content
if (require("curl")) {
fetch_url <- function(u) curl_fetch_memory(u)$content
ced_enc_detect(fetch_url("https://www.corriere.it"))
ced_enc_detect(fetch_url("https://www.vk.com"))
ced_enc_detect(fetch_url("https://www.qq.com"))
ced_enc_detect(fetch_url("https://kakaku.com"))
ced_enc_detect(fetch_url("https://www.incruit.com/"))
detect_enc_url <- function(u) ced_enc_detect(curl_fetch_memory(u)$content)
print(fetch_url("https://www.corriere.it"))
print(fetch_url("https://www.vk.com"))
print(fetch_url("https://www.qq.com"))
print(fetch_url("https://kakaku.com"))
print(fetch_url("https://etoland.co.kr"))
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment