Page 49 - Mercury Manual.book
P. 49

Mail Filtering Rules  44
                                                                                   Rule order, editing and examples



                                    when printing messages that have attachments – it is usually best to do an Attribute rule check
                                    before printing to suppress printing of such messages.

                                    Logical AND, Skip next rule, Goto a label, Call a label  The Logical AND action allows you
                                    to connect a groups of rules so that they must all trigger before the action in the final rule will
                                    be taken. This, and the other rule actions shown here constitute part of flow control, or con-
                                    trolling the order in which rules are processed. See below for more information on flow con-
                                    trol.

                                    Selecting many of the actions will cause Mercury to prompt you for extra information —
                                    Move and Copy, for instance, require you to select a folder, while Forward requires you to
                                    enter the address to which the message should be forwarded. Any extra information you have
                                    provided will appear in the grey area beneath the Action to take field on the window. You can
                                    change the parameter for the current rule without reselecting the action by clicking the Set
                                    button.

                                    Inserting text fragments (disclaimers)
                                    One very commonly-requested feature is the ability to insert text into a message. Many or-
                                    ganizations need to add disclaimer strings to messages sent to the outside world for legal rea-
                                    sons, and many people who use rules for automation may wish to insert text into a message
                                    indicating why something has happened. To do this in Mercury, create a rule for which the
                                    action is Insert text fragment.

                                    The process of inserting text into a message is actually very complicated, but Mercury is quite
                                    smart about it and can handle all the most common cases. When you create a rule with the
                                    Inserts text fragment action, you provide the rule with the name of a text file containing the
                                    text it should add. If you wish, you can create a second file in the same location and with the
                                    same name, but with the extension .HTM, containing simple HTML text that Mercury should
                                    insert into HTML documents. Mercury will insert the text version of the file into plain text
                                    message parts, and the HTML version into HTML parts (it is inserted immediately before the
                                    </HTML> tag at the end of the message). If you do not provide an HTML version of the text,
                                    Mercury will insert the text version in a <BLOCKQUOTE> section of the message, which is
                 Inserted HTML fragments   probably adequate for most situations. Note that if you provide an HTML part, it can include
                 can contain most HTML
                 formatting except for   most HTML formatting except for graphics.
                 graphics.
                                    Rule order, editing and examples


                                    The sequence of rules in the rule list is extremely important, since they are applied in the or-
                Rules are always proc-
                essed in the order they ap-  der they appear in the list (remember that rule processing stops as soon as the message is de-
                pear, and stop when the   leted or moved to another user). To change the ordering of the rule list, highlight the rule you
                message is deleted or re-
                directed to another user.  want to shift then click on the up or down buttons at the foot of the dialog.

                                    You can edit an existing rule in the rule list by highlighting it and clicking the Edit rule button,
                                    or by double-clicking it. Editing a rule is the same general process as creating one. You can
                                    delete a rule from the rule list by highlighting it and clicking the Delete button. Finally, to
                                    save the changes you have made to your rule list, click the OK button; if you want to discard
                                    your changes, press Cancel instead.

                                    Using rules – an example:  To create rules which would allow people to subscribe and un-
                                    subscribe to one of your mailing lists using the subject field instead of mail server commands
                                    in the message body, you might set up rules that look like this:

                                       If subject is Subscribe  then Add sender to list
   44   45   46   47   48   49   50   51   52   53   54