Chapter 10. Managing External Viewers with Mailcap

Table of Contents

A Short Intro to Mailcap
Parameters to Mailcap Entries
Reading of Mailcap Files
Fields
Mailcap Configuration
Some Sample Mailcap Entries

This document describes the support for Mailcap (RFC 1524) in ELinks. It does not describe the mailcap format. There are plenty of documents on the Web that does this. Google and thou wilt find. ;)

A Short Intro to Mailcap

Mailcap is a file format defined in RFC 1524. Its purpose is to inform multiple mail reading user agent (MUA) programs about the locally-installed facilities for handling mail in various formats. It is designed to work with the Multipurpose Internet Mail Extensions, known as MIME.

ELinks allows MIME handlers to be defined using its own configuration system, so why support mailcap? It can be seen as an alternative or simply as a supplement for setting up MIME handlers in ELinks. Mailcap files are present on most UNIX systems—usually in /etc/mailcap—so this makes it possible for ELinks to know how to handle a great variety of file formats with little configuration. To be able to use mailcap, it has to be compiled into ELinks. This is the default. If you don't need mailcap support, just configure ELinks with the flag: --disable-mailcap.