Browse Source

normalize params

master
Bob Rudis 8 years ago
parent
commit
9aeb6a6dcc
No known key found for this signature in database GPG Key ID: 1D7529BE14E2BBA9
  1. 4
      R/response.r
  2. 5
      man/tidy_html.Rd

4
R/response.r

@ -1,9 +1,7 @@
#' @param encoding specify the encoding when tidying an \code{httr} \code{response}
#' object. Default to "\code{UTF-8}".
#' @export
#' @rdname tidy_html
tidy_html.response <- function(content, options=list(TidyXhtmlOut=TRUE),
verbose=FALSE, encoding="UTF-8") {
verbose=FALSE) {
if (!grepl("html", content$headers[["content-type"]])) {
stop("htmltidy only parses HTML content from httr::response objects",

5
man/tidy_html.Rd

@ -12,7 +12,7 @@
\title{Tidy or "Pretty Print" HTML/XHTML Documents}
\usage{
\method{tidy_html}{response}(content, options = list(TidyXhtmlOut = TRUE),
verbose = FALSE, encoding = "UTF-8")
verbose = FALSE)
tidy_html(content, options = list(TidyXhtmlOut = TRUE), verbose = FALSE)
@ -41,9 +41,6 @@ or \code{XML} packages.}
\item{options}{named list of options}
\item{verbose}{output document errors? (default: \code{FALSE})}
\item{encoding}{specify the encoding when tidying an \code{httr} \code{response}
object. Default to "\code{UTF-8}".}
}
\value{
Tidied HTML/XHTML content. The object type will be the same as that of the input type

Loading…
Cancel
Save