The R Project SVN R

Rev

Rev 73574 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
54635 ripley 1
% File src/library/tools/man/HTMLheader.Rd
68948 ripley 2
% Part of the R package, https://www.R-project.org
67599 ripley 3
% Copyright 2009-2014 R Core Team
54635 ripley 4
% Distributed under GPL 2 or later
5
 
50445 murdoch 6
\name{HTMLheader}
56186 murdoch 7
\alias{HTMLheader}
73574 hornik 8
\title{Generate a Standard HTML Header for R Help}
50445 murdoch 9
\description{
10
This function generates the standard HTML header used on R help pages.
11
}
12
\usage{
52664 hornik 13
HTMLheader(title = "R", logo = TRUE, up = NULL,
61433 ripley 14
           top = file.path(Rhome, "doc/html/index.html"),
54057 ripley 15
           Rhome = "",
16
           css = file.path(Rhome, "doc/html/R.css"),
17
           headerTitle = paste("R:", title),
52664 hornik 18
           outputEncoding = "UTF-8")
50445 murdoch 19
}
20
\arguments{
21
  \item{title}{
22
The title to display and use in the HTML headers.  Should have had any
23
HTML escaping already done.
24
}
25
  \item{logo}{
88929 deepayan 26
Logical indicating whether to display the \R{} logo after the title, or
27
a character string giving the path of the logo to be displayed.
50445 murdoch 28
}
29
  \item{up}{
30
Which page (if any) to link to on the \dQuote{up} button.
31
}
32
  \item{top}{
33
Which page (if any) to link to on the \dQuote{top} button.
34
}
35
  \item{Rhome}{
54057 ripley 36
A \bold{relative} path to the R home directory.  See the \sQuote{Details}.
50445 murdoch 37
}
54057 ripley 38
  \item{css}{
39
The relative URL for the Cascading Style Sheet.
40
}
50445 murdoch 41
  \item{headerTitle}{
42
The title used in the headers.
43
}
44
  \item{outputEncoding}{
45
The declared encoding for the whole page.
46
}
47
}
48
\details{
49
The \code{up} and \code{top} links should be relative to the current page.
50
The \code{Rhome} path default works with dynamic help; for static help, a
66444 hornik 51
relative path (e.g., \file{../..}) to it should be used.
50445 murdoch 52
}
53
\value{
54
A character vector containing the lines of an HTML header which can be used
55
to start a page in the R help system.
56
}
57
\examples{
58
cat(HTMLheader("This is a sample header"), sep="\n")
59
}
60
\keyword{ utilities }
61
\keyword{ documentation }