SEARCH
NEW RPMS
DIRECTORIES
ABOUT
FAQ
VARIOUS
BLOG

BotDetect - Real-Time Bot Detection API
 
 

MAN page from PLD akanga-1.0.7-2.i586.rpm

MAN2HTML

Section: User Commands (1)
Updated: 16 May 1999
Index 

NAME

man2html - convert manual pages into HTML files 

SYNOPSIS

man2html [baseurl [manpage ...]]
man2html.cgi 

DESCRIPTION

man2htmltakes the output of the man(1) command and converts it into HTML.Manpage text in bold or italics is also in bold or italics in the HTML output.References to other command appear linked if they are found in themanpage list from the command line.
If baseurl is either omitted, empty or ``-'' man2html produceslinks to static files while otherwise the link addresses are made byappending the manual page's name to the baseurl (see below). 

Output format

The HTML output is enclosed in a <PRE>-tag.Page headers and footers are generally ommitted, only the header from thefirst page is printed.
The HTML file's title is taken from the manual page if the NAMEsection is found within the first 12 lines of the input. 

Input Format

To detect header and footers man2html makes some assumptions aboutthe output of the man command.The expected number of lines on a page is 66, including six lines of pageheader and 6 lines of page footer.If this doesn't match your man output you'll have to change thesettings at the beginning of the script (man2html is an awkscript). 

Referencing Manual Pages

Each reference to a manual page found in the input will be linked if themanual page if found in the manpage list from the command line.If this list is empty every reference will be linked.

In file-mode (when baseurl is either omitted, empty or a dash)man2html creates links to static files of the form

name-section.html

e.g. ls(1) would be HREF'ed as ls-1.html.

In cgi-mode the name of the manual page is directly appended tothe baseurl.The section number is separated from the name with a ``+'' which isURL-encoded a blank. 

CGI-Interface

man2html.cgi is a CGI-interface for man2html that allowsretrieving every manpage found on the system, listing manual sectionsand searching in the whatis(1) database.The mode of operation is controlled with the QUERY_STRING that theprogram receives.

Retrieving
The manpage name is appended to the URL like in

/cgi-bin/man2html.cgi?ls

It might be followed by a section namuber as in

/cgi-bin/man2html.cgi?ls+1

if there are manual pages in more than one section.If in this case the section is omitted man2html.cgi return the listof available manpages.

Searching
The whatis(1) database is automatically searched if one of thecharactes ``.'', ``?'' or ``*'' is found in theQUERY_STRING.In this case the QUERY_STRING is expected to be a whatis(1) compatiblesearch pattern.

/cgi-bin/man2html.cgi?ls*

lists all manpages starting with ls.

Sections
To list the contents of a section the section number is appended to thebaseurl:

/cgi-bin/man2html.cgi?1

The section number may be followed by a grep(1) compatible search patternwhich is then used to select the referenced items.

/cgi-bin/man2html.cgi?1+^ls

lists all manual pages from section 1 which description line start with ``ls''.

 

EXAMPLES

The following two example invocations

man ls | man2html >ls.html
man ls | man2html - >ls.html

produce HTML files with links to other static HTML files for every referencefound in the manpage.

man ls | man2html - -

doesn't link anything.

man ls | man2html - rm.1

links every occurence of a reference to rm(1) to the filerm-1.html. 

SEE ALSO

mancc(1).


 

Index

NAME
SYNOPSIS
DESCRIPTION
Output format
Input Format
Referencing Manual Pages
CGI-Interface
EXAMPLES
SEE ALSO

This document was created byman2html,using the manual pages.
 
ICM Bot detect detector