User Tools

Site Tools



This shows you the differences between two versions of the page.

Link to this comparison view

reference:spamrules_statement_getsectionencoding [2018/11/14 10:45] (current)
Line 1: Line 1:
 +======Spam Filter Rules: GetSectionEncoding======
 +^Statement ​ |GetSectionEncoding |
 +^Version ​ |2.3.9+ |
 +^Purpose ​ |Retrieves the MIME encoding method for the specified MIME section number, and returns the result into the specified variable |
 +The **GetSectionEncoding** statement requires a message section number and variable name, in the format
 +  GetSectionEncoding <message section number> <​variable name>
 +  ​
 +The returned encoding method will be a text string such as "​quoted-printable"​ or "​base64"​ etc.
 +Basic example, returning the result into the **${myEncoding}** variable
 +GetSectionEncoding 1 myEncoding
 +Using **GetSectionEncoding** with [[spamrules_statement_foreach|ForEach MimeSection]]
 +ForEach MimeSection SectionInfo
 + ​IfMatch ${SectionInfo} "/​^(\d+):​([\d\. ]*):​(.*?​):​(\d+):​(\d+):​(.*)$/"​
 +  ${SectionId} = ${1}
 +  GetSectionEncoding ${SectionId} myEncoding
 + EndIf
reference/spamrules_statement_getsectionencoding.txt ยท Last modified: 2018/11/14 10:45 (external edit)