(Added in v9.1)
This script is called when VPOP3 is mailing out (or considering mailing out) spamfilter quarantine reports. It allows customisation of the emailed reports and whether they're generated
function AreMailsNeeded(lastTimeEmailsSent)
returns mailsNeeded, untilTime
If this function doesn't exist, then it works on the configured schedule, and includes items up to the current time
function GetMsgLimit(username, itemLimit)
returns newItemLimit
This is called for each user, and indicates how many items will be included in the quarantine report emails (default 5000)
function GetSortOrder(username, existingSortOrder, numberOfItems, quarantineItems)
This is called for each user to whom an email will be sent, and allows customisation of the sorting of the items on the email.
returns newSortOrder
Possible sort orders are:
quarantineItems is a table of items, where each is:
function GenerateMessage(username, quarantineItems, numberOfItems, limitReached, userSettings)
returns messageSubject, messageTextContent, messageHtmlContent
This allows the script to generate the entire quarantine report message. If all three items are returned, then it overrides the automatic generation, otherwise VPOP3 will generate using the other settings/script results
function GetHtmlTemplate(username, quarantineItems, numberOfItems, limitReached)
returns filename, templateContents
“filename” contains a list of or more filenames, separated by ';'. In a filename '%base%' is replaced by the installation directory, '%temp%' is replaced by the temporary directory (usually the _temp subdirectory), '%exe%' is replaced by the directory where VPOP3.EXE is installed
The template file or “templateContents” should contain the HTML source for the email. It can contain control sequences
function GetHtmlOptions(username, quarantineServer, colour0, colour1, colour2, colour3)
returns newQuarantineServer, newColour0, newColour1, newColour2, newColour3
function GetTextTemplate(username, quarantineItems, numberOfItems, limitReached)
returns filename, templateContents
For “filename” see GetHtmlTemplate section above
The template file or “templateContents” should contain the Text source for the email. It can contain control sequences