Images in the database

Hi All,

Can someone please tell me how I can show database stored images within
a template. I’ve managed to show them
in a new screen with send_data but can’t seem to find how and if it’s
possible to show it in the template. The only thing I’ve tracked in
different references and books
are displaying it on a new page. So could someone tell me if I’m chasing
ghosts?

Kind regards,
Jeroen van Doorn

have you thought of trying acts as attachment or acts as column?

On 12/12/06, koloa [email protected] wrote:

have you thought of trying acts as attachment or acts as column?

I think maybe Koloa meant file_column rather than acts_as_column?

Both acts_as_attachment and file_column make it relatively easy to
upload
files (images) and store as blob.

You can find them along with all the other major plugin references at
http://wiki.rubyonrails.com/rails/pages/Plugins

Blessings,

Jeff

Hello Jeroen,

2006/12/12, Jeroen van Doorn [email protected]:

Can someone please tell me how I can show database stored images within
a template. I’ve managed to show them
in a new screen with send_data but can’t seem to find how and if it’s
possible to show it in the template. The only thing I’ve tracked in
different references and books
are displaying it on a new page. So could someone tell me if I’m chasing
ghosts?

You are 95% of the way there. You need an image tag that will display
the image. Since you already have an action that displays the image,
you simply need to tell the browser about it.

Hope that helps !

François Beausoleil
http://blog.teksol.info/
http://piston.rubyforge.org/

koloa schreef:

have you thought of trying acts as attachment or acts as column?

Nope, I’ll look into this. Thanx!

How about flex_image

http://beautifulpixel.textdriven.com/flex_image/index.html

I ve been using it and it is very handy to play with images.

On 12/12/06, Jeroen van Doorn [email protected] wrote:

different references and books
Hope that helps !


Carl-Gustaf H.

Francois B. schreef:

ghosts?


No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.409 / Virus Database: 268.15.15/581 - Release Date: 9-12-2006

Wow! I never thought of that … how stupid :slight_smile:

Thanx!

Would be another alternative, but I don’t need the extra options. So
such a plugin would make
my code(base) larger than nessacery. When I need to do image
manipulation in the future, I’ll definitly will use fleximage

Kind regards,
Jeroen

Is there any way to convert image type using flex_image or do i have to
go all the way down to RMagick? I’m anal-retentive and all my images
must be PNGs!