Indy 9
DecodeHeader
See Also, Unit: IdCoderHeader
Decodes an RFC 822 message header with content and/or character set encoding.
function DecodeHeader(Header: string): string;
Unit
IdCoderHeader
Parameters
Header: string
RFC message header to be decoded.
Return Value
String - Value fopr the decoded messsage header.
Description
DecodeHeader is a String function that decodes the RFC 822-compliant message header, specified in Header, that has content transfer or character set encodings.

DecodeHeader checks Header for the ISO character set encoding marker ("=?ISO") to determine when character set encoding has been applied to Header. DecodeHeader also look fofr the content transfer encoding markers for Base64 ("?B") or Quoted-Printable ("?Q") encoding. DecodeHeader then decodes all encoded characters until the final "?=" marker is located.

DecodeHeader will remove any Null strings (Decimal 0) embedded in the message header.


Created with Doc-O-Matic 2 donated to Project JEDI. Commercial license available from the Doc-O-Matic site.