url_accessible {xfun} | R Documentation |
Test if a URL is accessible
Description
Try to send a HEAD
request to a URL using
curlGetHeaders()
or the curl package, and see if it
returns a successful status code.
Usage
url_accessible(x, use_curl = !capabilities("libcurl"), ...)
Arguments
x |
A URL as a character string. |
use_curl |
Whether to use the curl package or the
|
... |
Arguments to be passed to |
Value
TRUE
or FALSE
.
Examples
xfun::url_accessible("https://yihui.org")
[Package xfun version 0.46 Index]