The R Project SVN R

Rev

Rev 68948 | Go to most recent revision | 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}{
26
Whether to display the \R{} logo after the title.
27
}
28
  \item{up}{
29
Which page (if any) to link to on the \dQuote{up} button.
30
}
31
  \item{top}{
32
Which page (if any) to link to on the \dQuote{top} button.
33
}
34
  \item{Rhome}{
54057 ripley 35
A \bold{relative} path to the R home directory.  See the \sQuote{Details}.
50445 murdoch 36
}
54057 ripley 37
  \item{css}{
38
The relative URL for the Cascading Style Sheet.
39
}
50445 murdoch 40
  \item{headerTitle}{
41
The title used in the headers.
42
}
43
  \item{outputEncoding}{
44
The declared encoding for the whole page.
45
}
46
}
47
\details{
48
The \code{up} and \code{top} links should be relative to the current page.
49
The \code{Rhome} path default works with dynamic help; for static help, a
66444 hornik 50
relative path (e.g., \file{../..}) to it should be used.
50445 murdoch 51
}
52
\value{
53
A character vector containing the lines of an HTML header which can be used
54
to start a page in the R help system.
55
}
56
\examples{
57
cat(HTMLheader("This is a sample header"), sep="\n")
58
}
59
\keyword{ utilities }
60
\keyword{ documentation }