I must admit I do not have must experience (yet) with Mimes and using the
different Content-Type so If someone can offer assistance on this one I
would be gratefull.

I want to convert this code to send a ZIP attachement without having to use
any other external, modules if possible. I want the code to be used on any
Unix server using the basic OS copnfiguration with Perl 5.0 or greater. I
think I need to use something like either Mime Base64 or uuencode but I am
not sure as to where to make the changes in the code.

This code will send a TEXT file attachement - I would like to send a ZIP
file instead. Does anyone have any simple solutions?

open (MAIL, "|$SENDMAIL -oi -t");
print MAIL "From: $ReplyFrom\n";
print MAIL "To: $supportE\n";
print MAIL "Subject: $data{'subject_email'}\n";
print MAIL "MIME-Version: 1.0\n";
print MAIL "Content-Type: multipart/mixed; "."boundary=\"8=--\"\n";
print MAIL "\n";
print MAIL "--8=--\n";
print MAIL "\n";
print MAIL "$VAR{'bodyUserinfo'}\n";
print MAIL "\n";
print MAIL "--8=--\n";

print MAIL "Content-Type: text/plain; ".    "charset=us-ascii\n";   print
MAIL "Content-Disposition: attachment; ".    "filename=\"wsr-pro.txt\"\n";

print MAIL "\n";

if (open CONF,"<wsr-pro.conf") {
while (<CONF>) { print MAIL }
close CONF;
print MAIL "\n";
print MAIL "\n";
}

=================

Any clues?

Normand Charette

_______________________________________________
Perl-Unix-Users mailing list. To unsubscribe go to 
http://listserv.ActiveState.com/mailman/subscribe/perl-unix-users

Reply via email to