Extract title, URLs, unique identifiers and date of release of press releases from the Department of Health website

get_doh_links(base = "https://www.doh.gov.ph/press-releases", pages = 1:25)

Arguments

base

Base URL for press releases in the Department of Health website. Default is https://www.doh.gov.ph/press-releases

pages

A vector of page numbers corresponding to the page panel containing the press release link. Default is 1:25. Press releases only go up to page 25. Values higher than 25 will error.

Value

A tibble of 4 columns: 1) absolute URLs of press release; 2) press release title; 3) press release unique identifier; and, 4) date of press release.

Examples

## Get press release URLs for first page of press release panel. The base ## argument has been specified using non-SSL version of base URL to prevent ## erroring for those with proxy server connections (i.e., in Travis tests) get_doh_links(base = "http://www.doh.gov.ph/press-releases", pages = 1)
#> # A tibble: 15 x 6 #> id title date source type url #> <dbl> <chr> <date> <chr> <chr> <chr> #> 1 4158 "DOH TO DEPUTIZE MED G… 2020-05-19 DOH press… http://www.doh.gov.ph… #> 2 4158 "DOH ENCOURAGES VIRTUA… 2020-05-18 DOH press… http://www.doh.gov.ph… #> 3 1311 "Malasakit: panlaban n… 2020-05-16 DOH press… http://www.doh.gov.ph… #> 4 5241 "EXPERTS RALLY BEHIND … 2020-05-14 DOH press… http://www.doh.gov.ph… #> 5 5241 "GOVERNMENT OFFERS FUL… 2020-05-14 DOH press… http://www.doh.gov.ph… #> 6 1452 "NEW QUARANTINE SITE I… 2020-05-13 DOH press… http://www.doh.gov.ph… #> 7 1920 "STATEMENT ON DATA INT… 2020-05-13 DOH press… http://www.doh.gov.ph… #> 8 8151 "HONORING NURSE’S DAY:… 2020-05-13 DOH press… http://www.doh.gov.ph… #> 9 1911 "SAN JUAN CITY THANKS … 2020-05-13 DOH press… http://www.doh.gov.ph… #> 10 1421 "ADB-Sponsored COVID-1… 2020-05-10 DOH press… http://www.doh.gov.ph… #> 11 5317 "ECQ Buys PH Time; Con… 2020-05-09 DOH press… http://www.doh.gov.ph… #> 12 2977 "BIGGEST MEGA SWABBING… 2020-05-08 DOH press… http://www.doh.gov.ph… #> 13 4211 "DUQUE THANKS NAVY FRO… 2020-05-07 DOH press… http://www.doh.gov.ph… #> 14 2018 "PH GOV’T RECEIVES 7 M… 2020-05-07 DOH press… http://www.doh.gov.ph… #> 15 2525 "BEYOND\tNUMBERS:\tWHA… 2020-05-07 DOH press… http://www.doh.gov.ph…