# Render :image =\> "whatever.png"?

**URL:** <https://www.ruby-forum.com/t/render-image-whatever-png/132574>\
**Category:** Rails\
**Created:** [March 21, 2008, 4:25pm UTC](https://www.ruby-forum.com/t/render-image-whatever-png/132574 "2008-03-21T16:25:14Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![namealreadytaken](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/97f17d/32.png) [@namealreadytaken](https://www.ruby-forum.com/u/namealreadytaken)\
**Post date:** [March 21, 2008, 4:25pm UTC](https://www.ruby-forum.com/t/render-image-whatever-png/132574/1 "2008-03-21T16:25:14Z")

</div>

In other words, is there some way to get Ajax to push an image?

Is there some reason this just can’t work? Or does it work already  
and my eyes skipped over it?

It would be nice, sometimes, to have RMagick or whatever generate an  
image on the fly and then write it to a part of the page. Think  
graphs based on database info. And so on.

Hmmm. I just thought of rendering a partial with a generated image  
tag. I guess an image could be given a temporary URL. I’d prefer to  
write it directly from memory, though.

F

---

<div class="post-metadata">

**Author:** ![namealreadytaken](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/97f17d/32.png) [@namealreadytaken](https://www.ruby-forum.com/u/namealreadytaken)\
**Post date:** [March 21, 2008, 5:36pm UTC](https://www.ruby-forum.com/t/render-image-whatever-png/132574/2 "2008-03-21T17:36:03Z")

</div>

On Mar 21, 2008, at 11:24 AM, fredistic wrote:

> Hmmm. I just thought of rendering a partial with a generated image  
> tag. I guess an image could be given a temporary URL. I’d prefer to  
> write it directly from memory, though.
> 
> F

Perhaps send\_file or send\_data will satisfy you.

-Rob

Rob B. [http://agileconsultingllc.com](http://agileconsultingllc.com)  
removed\_email\_address@domain.invalid
