From: "Yupapa" <[EMAIL PROTECTED]>
> nevermind... found out what was wrong!!
> thank you for reading BTW :p
>

The size of the $Buffer matters doesn't it ? ;-)

> "Yupapa" <[EMAIL PROTECTED]> źśźgŠóślĽó
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > HiHi~
> >
> > The problem is about EMAIL.
> > I am writing a web-based email for my school project and i have
> > problem doing attachments...
> >
> > I am using MIME:Base64 to encode and use Net::SMTP to send email.
> >
> > This is the code I use to encode files:
> >
> > $msg .= 'Content-type: application/octet-stream; name=""'."\n"; $msg
> > .= "Content-disposition: attachment; filename=\"$filename\";"."\n";
> > $msg .= 'Content-transfer-encoding: base64'."\n\n"; while ($Bytes =
> > read($_,$Buffer,1024)) {
> >  $msg .= encode_base64($Buffer)
> > }
> > close($_);

You'd better use Mail::Sender or MIME::Lite to generate the headers
and encode the files for you. It'll save you a lot of time.

Jenda
===== [EMAIL PROTECTED] === http://Jenda.Krynicky.cz =====
When it comes to wine, women and song, wizards are allowed
to get drunk and croon as much as they like.
        -- Terry Pratchett in Sourcery


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to