Toggle menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Sending an Email with Perl via Sendmail: Revision history

From John's Wiki

Diff selection: Mark the radio buttons of the revisions to compare and hit enter or the button at the bottom.
Legend: (cur) = difference with latest revision, (prev) = difference with preceding revision, m = minor edit.

4 October 2023

  • curprev 11:5311:53, 4 October 2023Admin talk contribs 787 bytes +787 Created page with "If your system has a <code>sendmail</code> compatible MTA installed you can use it in conjunction with the Perl script below to send an Email using Perl. <pre> #!/usr/bin/env perl $to = 'to@example.com'; $from = 'from@example.com'; $subject = 'Sent with Perl and Sendmail'; $message = 'This is test email sent using Perl and Sendmail.'; open(MAIL, "|/usr/sbin/sendmail -t"); # Email Header print MAIL "To: $to\n"; print MAIL "From: $from\n"; print MAIL "Subject: $subj..."