Use the MIME-tools-4.124 module + dependencies. It makes it a breeze to attach
documents.
Jon
"Mueller, Juergen (pro.vider GmbH iG)" wrote:
> Hello,
>
> I'm not quite sure if this is the right list for my question, anyway... ;-)
>
> If one wants to generate an email, the perl-code surely looks something like
> that:
>
> open(MAIL,"|$mailprog -t");
>
> print MAIL "To: info\@host.de\n";
> print MAIL "From: $input{'absender'}\n";
> print MAIL "Subject: Hallo Juergen\n\n";
> print MAIL "\n";
> print MAIL "Text der Email\n";
> print MAIL "blabla ...\n\n";
>
> close (MAIL);
>
> Questions:
> What is the code to attache a document to such a script-generated email?
>
> Thanks a lot.
>
> Juergen