# Display image problem

**URL:** <https://www.ruby-forum.com/t/display-image-problem/144184>\
**Category:** Rails\
**Created:** [July 26, 2008, 11:15am UTC](https://www.ruby-forum.com/t/display-image-problem/144184 "2008-07-26T11:15:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sijo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/da6949/32.png) [@sijo](https://www.ruby-forum.com/u/sijo)\
**Post date:** [July 26, 2008, 11:15am UTC](https://www.ruby-forum.com/t/display-image-problem/144184/1 "2008-07-26T11:15:27Z")

</div>

Hi  
I have to read a logo from DB and set in each page…I ahve a table  
named company with a BLOB field company\_logo  
So i wrote application controller code like  
after\_filter :logo\_set, :except =\> [:login,:process\_login]  
private  
def logo\_set  
@logo=CompanySetting.find(3)  
send\_data @logo.company\_logo, :type =\> “image”, :disposition =\>  
“inline”  
end

And my view has  
\<%= image\_tag("@logo.company\_logo", :alt =\> “Image”) %\>

 ..............(other html data) But what happens is only the image get displayed in browser no other html data ..Why this happens..Please help

Thanks in advance  
Sijo

|
| |

---

<div class="post-metadata">

**Author:** ![sijo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/da6949/32.png) [@sijo](https://www.ruby-forum.com/u/sijo)\
**Post date:** [July 26, 2008, 7:07pm UTC](https://www.ruby-forum.com/t/display-image-problem/144184/2 "2008-07-26T19:07:04Z")

</div>

Take look at:  
[http://mcubed.name/blog/articles/read/9](http://mcubed.name/blog/articles/read/9)

---

<div class="post-metadata">

**Author:** ![sijo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/da6949/32.png) [@sijo](https://www.ruby-forum.com/u/sijo)\
**Post date:** [July 28, 2008, 10:16am UTC](https://www.ruby-forum.com/t/display-image-problem/144184/3 "2008-07-28T10:16:04Z")

</div>

Hi  
Thanks for the reply…This I had already tried…Then I get the above  
problem…ie Only the image get displayed Not other data in the page

Sijo
