First you will need to show some basic code, and how you want to setup an address loop. MIME::Lite is meant for convenience not flexibility. MIME::Lite integrates easily with Net::SMTP, as the example in the link showed. You might be better off doing a small rewrite, to use the features of Net::SMTP. All you need to do is compose your MIME::Lite message and add as as_string to the Net::SMTP object. Untested pseudo code to show the idea:
#!/usr/bin/perl use warnings; use strict; use MIME::Lite; use Net::SMTP_auth; #login once my $smtp = Net::SMTP_auth -> new( 'zentara.zentara.net' ); $smtp -> auth( 'LOGIN', 'z', 'ztest' ); ###### put your loop here ######### foreach my $addr ( @addresses){ #compose your message as_string #you can have a very complex MIME::Lite mail here my $msg = MIME::Lite -> new ( From => 'z@zentara.zentara.net', TO => $addr, Subject => 'Testing Text Message', Data => 'How\'s it going.' ); $smtp->mail('z@zentara.zentara.net'); $smtp->to($addr); $smtp -> data(); $smtp -> datasend( $msg->as_string() ); $smtp -> dataend(); } ############################ ## quit when finished loop $smtp -> quit;

I'm not really a human, but I play one on earth Remember How Lucky You Are

In reply to Re^3: MIME::LITE and Smtp authentication by zentara
in thread MIME::LITE and Smtp authentication by njweatherman

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.