Tools to Work with the 'Splash' JavaScript Rendering Service in R
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

69 рядки
2.6KB

  1. #' @rdname splash_user_agent
  2. #' @export
  3. ua_splashr <- sprintf("splashr/%s", packageVersion("splashr"))
  4. #' @rdname splash_user_agent
  5. #' @export
  6. ua_win10_chrome <- "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36"
  7. #' @rdname splash_user_agent
  8. #' @export
  9. ua_win10_firefox <- "Mozilla/5.0 (Windows NT 10.0; WOW64; rv:51.0) Gecko/20100101 Firefox/51.0"
  10. #' @rdname splash_user_agent
  11. #' @export
  12. ua_win10_ie11 <- "Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko"
  13. #' @rdname splash_user_agent
  14. #' @export
  15. ua_win7_chrome <- "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36"
  16. #' @rdname splash_user_agent
  17. #' @export
  18. ua_win7_firefox <- "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:51.0) Gecko/20100101 Firefox/51.0"
  19. #' @rdname splash_user_agent
  20. #' @export
  21. ua_win7_ie11 <- "Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko"
  22. #' @rdname splash_user_agent
  23. #' @export
  24. ua_macos_chrome <- "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36"
  25. #' @rdname splash_user_agent
  26. #' @export
  27. ua_macos_safari <- "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/602.3.12 (KHTML, like Gecko) Version/10.0.2 Safari/602.3.12"
  28. #' @rdname splash_user_agent
  29. #' @export
  30. ua_linux_chrome <- "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36"
  31. #' @rdname splash_user_agent
  32. #' @export
  33. ua_linux_firefox <- "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:51.0) Gecko/20100101 Firefox/51.0"
  34. #' @rdname splash_user_agent
  35. #' @export
  36. ua_ios_safari <- "Mozilla/5.0 (iPad; CPU OS 10_2 like Mac OS X) AppleWebKit/602.3.12 (KHTML, like Gecko) Version/10.0 Mobile/14C92 Safari/602.1"
  37. #' @rdname splash_user_agent
  38. #' @export
  39. ua_android_samsung <- "Mozilla/5.0 (Linux; Android 7.0; SM-G892A Build/NRD90M; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/60.0.3112.107 Mobile Safari/537.36"
  40. #' @rdname splash_user_agent
  41. #' @export
  42. ua_kindle <- "Mozilla/5.0 (X11; U; Linux armv7l like Android; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/533.2+ Kindle/3.0+"
  43. #' @rdname splash_user_agent
  44. #' @export
  45. ua_ps4 <- "Mozilla/5.0 (PlayStation 4 3.11) AppleWebKit/537.73 (KHTML, like Gecko)"
  46. #' @rdname splash_user_agent
  47. #' @export
  48. ua_apple_tv <- "AppleTV6,2/11.1"
  49. #' @rdname splash_user_agent
  50. #' @export
  51. ua_chromecast <- "Mozilla/5.0 (CrKey armv7l 1.5.16041) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.0 Safari/537.36"