This script converts IRC logs in UTF-8 to HTML pages, while attempting to stay as close to no parsing as feasible.
The generated web page contains an anchor for each line so that you can jump to and link to specific lines, and cut-off links to select a particular portion of the log. Links in conversation will also be clickable.
irclog2html \#foo.1.log \#foo.2.log > channel-foo.log.html
If the script detects that it was run in a CGI environment, it
will look at the
PATH_TRANSLATED environment variable for
the filename to read. The assumption is that the script will
be run by the web server to handle requests against particular
Put it somewhere for your web server to find, eg.:
ln -s `which irclog2html` /var/www/cgi-bin/irclog2html.cgi
Then add something like the following lines to
to your Apache configuration:
AddCharset utf-8 .irclog AddType text/x-irclog .irclog Action text/x-irclog /cgi-bin/irclog2html.cgi
After that, any file with the extension
.irclog in your web
server’s document root will automatically be rendered as an