Creating News Filters


Overview
Filters are one of the most important features of any email or news client. Filters can be used to weed out spamming which is becoming an increasing problem - just create a spam filter, and set it to watch the newsgroups and email accounts you want, and you will see that 95% of the spam-mail you get disappears.

You can also use filters to seperate email received from mailinglists - just create a custom folder for each mailingslist, and set a filter to move email from mailinglists, from you incoming folder to the custom folder. This makes reading email in especially very active mailinglists painless.

Creating a filter
To create a filter, enter the settings notebook, and you will see a list of filters. From there, you can add, delete or change filters.

Guide to creating SPAM filters
A SPAM filter is a filter that removes most of the "Earn $$$ fast" emails and news articles, here is a step-by-step guide to create a simple spam-filter.

Create a custom folder called "Spam" (select "Create custom folder" from the Newsgroup menu)
Create a new filter (select "Add" in the settings notebook) - call it "Spamfilter"
Set the target to "Incoming News"
Add a condition, and select "Advanced search". Set the condition to "Crossposted to more than x groups", and set the value to 3
Set the action to "Copy to custom folder", and "Delete", remember to set the custom folder to "Spam" - the custom folder you have created.
Save the filter

That's it, now you've got your own spam filter that will weed out most of the spam in all the newsgroups. You can also add more conditions to the search, just remember to set the filter to process when one condition is met, otherwise all the conditions have to be met, to execute the action.

In the above example, all spam messages will be moved to the "Spam" folder, and you can later review them, or delete them.

Experiment with the actions in filters, just remember that if you delete something, it's lost, so until you are sure that a filter works, don't set it to delete messages, especially if you are filtering your own mail messages :) Test filters, by setting the action to Beep.

Filter actions
The following is a description of all currently available actions

Download body
This action only has meaning for news articles - it tells IA to download the message body immediately. It is often usefull if you scan for a word in the subject, or a special author in certain newsgroups, and want to see everything with this subject or author. If this action is triggered, no other actions will be performed, the complete article will be downloaded, and then refiltered. Once it is refiltered, the other actions will be executed.

Execute REXX
This action executed a rexx script, the script can the modify the retrieved message, and eg. verify PGP certificates, decrypt messages, or whatever other action it wants to take. The entire message will be saved, in RFC-822 format, including all received headers. The script is called with the filename as parameter. The rexx script must return "CHANGED" if it has changed the message, and "NOTCHANGED" if it hasn't changed anything. IA treats any unknown returncode as changed, and rereads the message.

An example of an add-on program that uses REXX filters is Bandit Tagger, which can add taglines to outgoing messages.

A note to script writers: The script will be run in the background, and should not expect to be able to write anything to the screen while executing, it certainly should not expect to be able to obtain input from the user.
Also, the script should complete it's processing as fast as possible, since it will delay retrieval of other messages, until the script has finished executing.

Alert
This action either beeps, or plays a .WAV file when the action is triggered - it is mostly useful for testing filters, or for filters which aren't triggered too often.

Auto-Reply
This is not supported at the moment, but when it is, you will be able to send an auto-reply to the sender.

Forward-to
This is not supported yet, but will soon allow you to forward this message to another email address.

Change score
This is also nonsupported at the moment, but when finished, it will allow you to change the score of a message, and you will also be able to sort articles, based on their score.

Copy to custom folder
This action copies the message to a custom folder, if the message cannot be copied for some reason, if eg. there is already another message with the same message-id in the folder, the remaining actions are not executed. This is done, so a message will not be deleted if it couldn't be copied to another folder first.

Delete
Setting the delete action, deletes the message from either the newsgroup, or the incoming mail folder. Be sure to copy the message to a custom folder first, if you aren't 100% sure you don't want to see it.

Stop filtering
Normally, all filters are executed in alphabetic order, until a filter deletes the message, but if you for some reason do not want other filters to see this message, tell IA to execute this action.



[Help Index] [Features] [Support] [Register]

Copyright 1998 - All Rights Reserved - Adventure Software