Stewart,
I use the Mail::Sendmail package on my windows machine to send email with my
scripts.
I honestly haven't tested it on a Unix platform yet (building a machine
now), but I would
imagine it should work on Unix also.
Craig
[EMAIL PROTECTED]
Pager
Numeric: 1-877-895-3558
Email pager: [EMAIL PROTECTED]
--------------------------------------------------------------
You will never find time for anything.
If you want time, you must make it.
Charles Buxton
----- Original Message -----
From: "Stewart Watkiss" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, July 09, 2001 8:54 AM
Subject: SMTP - outgoing email
> Hello,
>
> Please can someone help with an SMTP problem I'm having.
>
> I am trying to use SMTP to send emails using PERL. I can't use sendmail
> etc. as this needs to work on both Win32 and UNIX (unless anyone knows of
a
> free email client that can be called from Perl that works on Win32 and
> UNIX). I am doing this for a charity which has an SMTP server I can
access.
> To prevent the SMTP server from being used to generate spam it only
accepts
> emails destined for the charity or those from valid email users on the
> charity's servers.
>
> The charity is setup into regions so there may be:
>
> [EMAIL PROTECTED]
> and
> [EMAIL PROTECTED]
> etc.
>
> There are also aliases for example there may be
> [EMAIL PROTECTED] which aliases to [EMAIL PROTECTED]
> I'm not sure how the aliases are setup, but this is on a NT based mail
> server.
>
> I first tried using the standard SMTP calls from within perl however these
> were ignored. I then realised that it appears to look at the headers
within
> the data (so by sending "To: user@xxxxxxx \n From: user@xxxxx" it would
> send emails. This does not however work when sending to the alias
addresses
> on that server, it returns user not known.
>
> Using the same server and netscape as the email client has no problems.
>
> Looking at the emails sent using netscape there are considerably more
> headers than when using perl eg:
>
> with SMTP (MDaemon.PRO.v4.0.3.R)
> for (real address - not alias)
>
> and
>
> X-MDaemon-Deliver-To: (points to real address not alias)
>
> Looking at these I guess there is either something I must to to find out
> the real name of any alias on that server, or maybe I need to add some
more
> headers? Can anyone give any suggestions about the extra things netscape
> does when sending an email?
>
> Any help greatly apreciated
>
> Thanks
> Stewart
>
> PS. I've attached a copy of my basic source code (used for testing at the
> moment).
>
> (See attached file: smtptest.pl)
>
> Note: The content of this email is my personal opinion and does not
> represent the views of any organisations or companies I am associated
with.
>