avoiding Spam rules when building emails

Giganews Newsgroups
Subject: avoiding Spam rules when building emails
Posted by:  John Evans (johneva…@clear-Advantage.co.uk)
Date: Thu, 14 Apr 2005

Dear all,
        I have code for building emails that have html code, and possibly
attachements.
The code was suggested by someone at Indy and works fine.
BUT, a Spam filter is quaranteeing the email because it gets a high Spam
score.
The biggest scores are caused by

2.35 MIME_BOUND_RKFINDY    Spam tool pattern in MIME boundary (rfkindy)

1.70 MSGID_FROM_MTA_ID      Message-Id for external message added locally

1.50 MPART_ALT_DIFF        BODY: HTML and text parts are different

Does anyone have any suggestions for coding around these problems.

My (relevant) code is:

      email.Body.Clear;  //email is the TidMessage component
      email.ReplyTo.Clear;
      email.Recipients.Clear;
      email.From.Address := trim(datamodform.qparamsemailfrom.AsString);
      email.Sender.Address  :=trim(datamodform.qparamsemailfrom.AsString);

email.ReplyTo.Add.address:=(trim(datamodform.qparamsemailfrom.AsString));
      email.Recipients.Add.address
:=trim(queryname.FieldbyName('email').AsString);

          email.Subject:=edAnalysisSubject.Text;
          memo1.clear;
          with Tidtext.Create(email.MessageParts, memo1.lines) do
          begin
            ContentType := 'text/plain';
          end;
          memo1.Lines.Add(emailtext.Text);  // this is just copying the
separately built html into a memo component.
          with Tidtext.Create(email.MessageParts, memo1.lines) do
          begin
            ContentType := 'text/html';
          end;

--
John Evans
Managing Director
Clear Advantage Ltd

www.Clear-Advantage.co.uk

Replies