On Mon, Mar 8, 2010 at 3:40 PM, theduz <[email protected]> wrote:

>    attachment :content_type => "message/external-body; access-
> type=URL;" do |a|
>      a.transfer_encoding = "binary"
>      a.body = "URL=\"http://www.biltd.com\"\n\nContent-type: text/html
> \nContent-Transfer-Encoding: Binary\n\nTHIS IS NOT THE BODY!\n"
>    end

> Content-Type: message/external-body; access-type=URL
> Content-Transfer-Encoding: Binary
> Content-Disposition: attachment; access-type=URL
>
> URL="http://www.biltd.com";
>
> Content-type: text/html
> Content-Transfer-Encoding: Binary
>
> THIS IS NOT THE BODY!
>
> Which doesn't look quite like RFC2017 shows.  There seems to be an
> extra new line, and a couple extra headers.  RFC2017 expects the mime
> body to look like:
>
>
>
> Content-type: message/external-body; access-type=URL;
>                  URL="http://www.foo.com/file";
>
> Content-type: text/html
> Content-Transfer-Encoding: binary
>
> THIS IS NOT REALLY THE BODY!

Not tested:

 attachment :content_type => "message/external-body; access-
type=URL; URL=URL=\"http://www.biltd.com\""; do |a|
     a.transfer_encoding = "binary"
     a.body = "THIS IS NOT THE REAL BODY!\n"
   end


-- 
Rick DeNatale

Blog: http://talklikeaduck.denhaven2.com/
Twitter: http://twitter.com/RickDeNatale
WWR: http://www.workingwithrails.com/person/9021-rick-denatale
LinkedIn: http://www.linkedin.com/in/rickdenatale

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to