Description Usage Arguments Value Examples
View source: R/create_error_page.R
Defines a new page for any http error status. These pages are always html (mime = text/html) but can use any number of resources (css, png, js, ...) which must be uploaded appropriately using link_web_resource().
1 | create_error_page(http_status, html, host = .host.)
|
http_status |
The http status code returned as an error. Only those specified in Jazz API. E.g., 400 (Bad Request) - Syntactical error at top level. (Malformed URI) |
html |
The html page to be served for that error. |
host |
(Optional) the name of the jazz server host (including the port). Usually set just once via set_jazz_host(). |
Returns TRUE on success or throws an error on failure.
1 2 3 4 5 | ## Not run:
page <- '<html>\n<body>\n<br/>Resource was not found on this node.\n</body>\n</html>'
create_error_page(404, page)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.