url_parse | R Documentation |
url_parse()
parses a URL into its component parts, powered by
curl::curl_parse_url()
. The parsing algorithm follows the specifications
detailed in RFC 3986.
url_parse(url, base_url = NULL)
url |
A string containing the URL to parse. |
base_url |
Use this as a parent, if |
An S3 object of class httr2_url
with the following components:
scheme
, hostname
, username
, password
, port
, path
, query
, and
fragment
.
Other URL manipulation:
url_build()
,
url_modify()
url_parse("http://google.com/")
url_parse("http://google.com:80/")
url_parse("http://google.com:80/?a=1&b=2")
url_parse("http://username@google.com:80/path;test?a=1&b=2#40")
# You can parse a relative URL if you also provide a base url
url_parse("foo", "http://google.com/bar/")
url_parse("..", "http://google.com/bar/")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.