Hi,
I wrote a piece of code which automatically fetches the html content from a online repository.
It works fine from RStudio on Linux, Win 10 and mac OS but whenever I run it using just R (without RStudio), I get this error:
Error curl::curl_fetch_memory(url, handle = handle) :
Received HTTP/0.9 when not allowed
The code I am running looks like this (! is not a workable example, sorry):
for (i in 1:100) {
txt <- url(paste0("http://www.mywebsite.com/show?", i), encoding = "UTF-8")
txt1 <- read_html(txt)
}
Hi, I wrote a piece of code which automatically fetches the html content from a online repository. It works fine from RStudio on Linux, Win 10 and mac OS but whenever I run it using just R (without RStudio), I get this error:
The code I am running looks like this (! is not a workable example, sorry):
Thanks in advance for any help!