Calling Image File

I’ve this small test app where I’m saving a user profile picture in a
subdirectory under “public” folder. Now when a user uploads a picture -
a unique directory is created under his id and then his/her image is
stored there. Now while retrieving the image I only get the path name
and nothing else. How can I get the image shown in the browser…HELP
PLEASE!!!

On Jul 31, 2006, at 12:22 PM, Mister Stylizedgeek wrote:

I’ve this small test app where I’m saving a user profile picture in a
subdirectory under “public” folder. Now when a user uploads a
picture -
a unique directory is created under his id and then his/her image is
stored there. Now while retrieving the image I only get the path name
and nothing else. How can I get the image shown in the browser…HELP
PLEASE!!!

No need to shout. Have you first checked that the image is getting
stored properly? Then check to see if you can browse straight to the
image in your web browser.

If both those work then you probably have an error in your image tag
in your view.
-Mat

Mat S. wrote:

On Jul 31, 2006, at 12:22 PM, Mister Stylizedgeek wrote:

I’ve this small test app where I’m saving a user profile picture in a
subdirectory under “public” folder. Now when a user uploads a
picture -
a unique directory is created under his id and then his/her image is
stored there. Now while retrieving the image I only get the path name
and nothing else. How can I get the image shown in the browser…HELP
PLEASE!!!

No need to shout. Have you first checked that the image is getting
stored properly? Then check to see if you can browse straight to the
image in your web browser.

If both those work then you probably have an error in your image tag
in your view.
-Mat

I already checked, everything displays in the browser correctly when
called direct. And as an FYI, I’m not SHOUTING!

On Jul 31, 2006, at 12:45 PM, Mister Stylizedgeek wrote:

and nothing else. How can I get the image shown in the

I already checked, everything displays in the browser correctly when
called direct. And as an FYI, I’m not SHOUTING!

Dude, you like, totally were. There were even bangs involved. :slight_smile:

Anyway. Do view source on the HTML, the path to the file is probably
wrong or the tag is malformed Are doing this under apache by any
chance? I’ve had trouble with the “public” directory being in the
wrong place when using apache previously.
-Mat

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs