CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Perl Programming Help: Advanced:
mail size increase


New User

Oct 23, 2008, 2:14 AM

Post #1 of 2 (1235 views)
mail size increase Can't Post

i want to reconstruct mail form mime mail.put it in to imap server using Mail::IMAPClient module.

every thing works fine.
but when i append the mail in IMAP server using Mail::IMAPClient's append_string method, the size of the mail increases.

my code is something like this

$mimeent = generatemail(); # this func return mime entity.  
print "length before: " . length($mimeent->as_string);
my $newid =$imap->append_string($folder, $mimeent->as_string, $flags, $date);
print "length after: " .$imap->size($newid);

the o/p is:
length before: 337119
length after: 342662

According to documentation of append_sting method:
Note that many servers will get really ticked off if you try to append a message that contains "bare newlines", which is the titillating term given to newlines that are not preceded by a carrage return. To protect against this, append_string will insert a carrage return before any newline that is "bare". If you don't like this behavior then you can avoid it by not passing naked newlines to append_string.

I checkd that the data contain the CRLF.

so i am not getting why the size of mail increse ..??
any hint ..??


Oct 23, 2008, 10:01 AM

Post #2 of 2 (1219 views)
Re: [luckypower] mail size increase [In reply to] Can't Post

CRLF is that the same as \r\n?


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives