in reply to Re^5: need help with FTP script
in thread need help with FTP script

hi Roy

I've changed but still doesn't work.
I think without -t, because:
" sendmail: fatal: cannot handle command-line recipients with -t "

I don't understand, if I try only this simply mail script then works well and I get mails:
#!/usr/bin/perl -w my $recipient = "xxx\@mydomain.net"; my $sender = "yyy\@mydomain.net"; open(MAIL, "|/usr/sbin/sendmail -t") || die "Cant send mail. Reason: $ +!"; print MAIL "from:$sender\n"; print MAIL "to:$recipient\n"; print MAIL "subject: test mail\n"; print MAIL "Time: ", scalar localtime, "\n"; close(MAIL);
I think the problem is the combination with the transfer script.

kind regards
cc

Replies are listed 'Best First'.
Re^7: need help with FTP script
by cc (Beadle) on Jun 16, 2004 at 16:03 UTC
    I've found out:

    the mail should be send before "die"

    thanks anyway.

    greetings
    cc