in reply to Sending email

Either use BCC rather than To, or send one mail at a time within the for loop, rather than push each email to an array.

Replies are listed 'Best First'.
Re^2: Sending email
by frank1 (Monk) on Jul 21, 2023 at 12:34 UTC

    when i try something like this

    my $email_s = Email::Simple->create( header => [ Bcc => $tostring, From => 'xxx@xxxx.com', Subject => "test hi", 'Content-Type' => 'text/html', ], body => $message_s,

    this is the response

    no recipients

      Bcc doesn't count as recipients - by design. You need at least one recipient on the To line. People usually put themslelves in that field.

        Its the same, because this is the output

        from: xxxx@xxx.com to: me@email.com bcc: recpt1@email.com, recpt2@email.com date: Jul 21, 2023, 9:13 PM subject: test hi mailed-by: xxxx.xxxx.com signed-by: xxxx.com security: Standard encryption (TLS) Learn more

        code

        my $email_s = Email::Simple->create( header => [ To => 'me@email.com', Bcc => $tostring, From => 'xxx@xxxx.com', Subject => "test hi", 'Content-Type' => 'text/html', ], body => $message_s,