info.mailtraq.com > Management > Script Functions A-Z > SetHeader() SetHeader()Sets the specified header field of the current message to the given value. In cases where the specified field occurs more than once, only the first instance of the field is changed. Note that the field separator used in headers, ":" (ASCII 58) a colon, must not be quoted when referring to header names.
SetHeader( field , value )
- field
- The field name to modify in the message header as a string
- value
- The string contents to assign to the specified field
// Set the From header of the current message
If(UserOf(Header("To")) = "webmaster",
SetHeader("From", AddressOf("webmaster"),
SetHeader("From", AddressOf("postmaster")
) |