browse UNIX man pages through WWW

version 1.16

Man-cgi is shell-sed-awk script which converts on the fly the output of the "man" command to HTML.

Here is the normal output of the command "man elm" and the same man page formatted with Man-cgi.

Here is the source of Man-cgi. Special versions of man-cgi are also available:


Man-cgi is made to be used as a cgi program from an HTTPD server. In order to work properly following things should be done by the server administator:
  1. Copy the script itself in the /cgi-bin/ directory of the server.
  2. Turn on the "execute" bit of the script : chmod +x man-cgi
  3. Edit the Configuration Section of the script. That section contains five variables that should be adjusted (PATH,MANPATH,MANCGI,DOT,PAGES).
  4. You would probably want to get local copies of the two images that Man-cgi uses. These images are:


When called without arguments (http://www-server/cgi-bin/man-cgi) it outputs a "Front Page" with a section list and query form. When called with arguments, the first argument is the topic (e.g. ls) and the second argument (optional) is the section to look in.



Handle Local File Include Vulnerability.
Multiple blank lines are supressed.
Man-cgi now recognizes cross-references that contain periods (e.g.
Really fixed problems occuring in pages which used multi-overstrike for emboldening (hopefully).
Fixed problems occuring in pages which used multi-overstrike for emboldening. Now Man-cgi works any number of overstrike.
Fixed problem with hyphenated cross-references.
and earlier, no history at that time...

TODO list

Here are some things that I may add to the script:
Panagiotis Christias,