Re: Help: automated email forwarding similar to .forward



On 7/27/05, Rich Fernandez <rfernandez@xxxxxxxxx> wrote:
> Thanks Wiggins,
>
> > As far as reading the message in,
> > parsing it, and then forwarding it, I guarantee the Mail::Box
> > suite can
> > handle what you want, but it does have a learning curve.
>
> You are right, I did not read the doco carefully enough. Sorry.
>
> > Sorry I can't provide source what I wrote was under license,
> >
>
> No prob, I can work that out for myself.
>
> Thanks again to you and the others that responded.
>
> richf
>
> --
> To unsubscribe, e-mail: beginners-unsubscribe@xxxxxxxx
> For additional commands, e-mail: beginners-help@xxxxxxxx
> <http://learn.perl.org/> <http://learn.perl.org/first-response>
>
>
>

Rich,

To flesh out Wiggins' response a little, I would do something like this:

use forward to pipe the mail that will take the messages and write
them to a specific directory. You can use something in the Mail::* or
MIME::* suites to parse them and save them in a usable format, and add
a "this message has been forward from" announcement if you want. Use
File::Temp or similar to give each a unique filename, preferably based
on the original or new recipients' email.

Then write a script based on Mail::Mailer or MIME:Lite to go through
the directory and mail them back out at your convenience. You can
write it as a daemon, run it as a cron job, or just run it from the
command line, depending on your needs. If you put useful information
in the filenames, you can easily send just the mail to one remote
user, or just them mail to one of the local users being forwarded.

HTH,

-- jay
--------------------------------------------------
This email and attachment(s): [ ] blogable; [ x ] ask first; [ ]
private and confidential

daggerquill [at] gmail [dot] com
http://www.tuaw.com http://www.dpguru.com http://www.engatiki.org
.



Relevant Pages

  • Re: Book on Pre-MATH for cryptography and cryptanalysis.
    ... Plenty of furious high draft assists philosophys in response to ... Where doesn't Donald occupy altogether? ... Everyone sing useful councillors after the evolutionary educational ... suite, whilst Mohammad over glances them too. ...
    (sci.crypt)
  • Group Policy and Local Users and Groups
    ... of our suite and I am having some problems. ... that extends the Local Users and Groups snap-ins. ... have decided to extend the Security Settings snap-in to add our policies. ...
    (microsoft.public.security)
  • Group Policy and Local Users and Groups
    ... of our suite and I am having some problems. ... that extends the Local Users and Groups snap-ins. ... have decided to extend the Security Settings snap-in to add our policies. ...
    (microsoft.public.win2000.security)