Parse a MediaWiki page url into its component parts (wiki name, wiki type, and page title). Supports both static page urls and their equivalent API calls.
See also
Other MediaWiki functions:
wt_wiki_page_parse()
,
wt_wiki_page()
,
wt_wiki_url_build()
Examples
wt_wiki_url_parse(url="https://en.wikipedia.org/wiki/Malus_domestica")
#> $wiki
#> [1] "en"
#>
#> $type
#> [1] "wikipedia"
#>
#> $page
#> [1] "Malus_domestica"
#>
wt_wiki_url_parse("https://en.wikipedia.org/w/api.php?page=Malus_domestica")
#> $wiki
#> [1] "en"
#>
#> $type
#> [1] "wikipedia"
#>
#> $page
#> [1] "Malus_domestica"
#>