# Inline\_attachment not working properly?

**URL:** <https://www.ruby-forum.com/t/inline-attachment-not-working-properly/145355>\
**Category:** Rails\
**Created:** [August 8, 2008, 10:24am UTC](https://www.ruby-forum.com/t/inline-attachment-not-working-properly/145355 "2008-08-08T10:24:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![steve](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/f19dbf/32.png) [@steve](https://www.ruby-forum.com/u/steve)\
**Post date:** [August 8, 2008, 10:24am UTC](https://www.ruby-forum.com/t/inline-attachment-not-working-properly/145355/1 "2008-08-08T10:24:46Z")

</div>

We are using the inline\_attachment gem for emails. This gem  
overloads the image\_tag method. However, we get an error whenever we  
send it a full URL, such as comes back from the AWS-S3 (Amazon) gem.

image\_tag( ‘[http://www.test.com/foobar.jpg](http://www.test.com/foobar.jpg)’)

results in the following error message

Error emailing discussion: No such file or directory - /Users/SteveK/  
development/OnePlace/Home/publichttp://www.test.com/foobar.jpg

As you can see, the inline\_attachment gem incorrectly assumes that it  
needs to add the RAILS\_ROOT path to the beginning. This is not the  
issue with the standard rails version of image\_tag.

Has anyone found a work around / fix? Is there something that I am  
doing wrong?

Steve
