Header Types
Because all headers are modeled on different data (dates, addresses, text…) there are different types of Header in Swift Mailer. Swift Mailer attempts to categorize all possible MIME headers into more general groups, defined by a small number of classes.
-
Text Headers
Text headers are the simplest type of Header. They contain textual information with no special information included within it – for example the Subject header in a message. -
Parameterized Headers
Parameterized headers are text headers that contain key-value parameters following the textual content. The Content-Type header of a message is a parameterized header since it contains charset information after the content type. -
Date Headers
Date headers contains an RFC 2822 formatted date (i.e. what PHP's date('r') returns). They are used anywhere a date or time is needed to be presented as a message header. -
Mailbox (e-mail address) Headers
Mailbox headers contain one or more email addresses, possibly with personalized names attached to them. The data on which they are modeled is represented by an associative array of email addresses and names. -
ID Headers
ID headers contain identifiers for the entity (or the message). The most notable ID header is the Message-ID header on the message itself. -
Path Headers
Path headers are like very-restricted mailbox headers. They contain a single email address with no associated name. The Return-Path header of a message is a path header.