----- Original Message -----
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, June 13, 2000 9:13 AM
Subject: [REBOL] solved (was detach-image: func (was: %detach.r ) ) Re:(6)


> This now works (with .jpg images, at least)...

The reason for that is below..

> parse/all email-contents [thru {base64^/^/} copy text to {==} (append
> > > image-code text)]

 = is only used for  padding in Base64  There is no guarantee that == will
be the terminator of base64 encoded data.

To find the end you have to go to start of the boundary and trim the excess.

parse/all email-contents [thru {base64^/^/} copy text to {--} (append
image-code trim copy text)]

It will work more reliably. "--" will begin a boundary and "-" cannot appear
as a char inside base64.


Cheers,

Allen K



Reply via email to