Forum: Ruby on Rails Strange Rendering with img_tag

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
1c0cd550766a3ee3e4a9c495926e4603?d=identicon&s=25 (Guest)
on 2007-07-23 15:52
(Received via mailing list)
I need some advice on img_tag()
I checked in the console, and the file name of the image is stored
>> puts a.file_name

The file is stored on the file system itself. In public/images/

However, when the page is rendered, there is a strange string appended
to the image name in the img element, like so:
<img alt="Dog_whisper_lowres" src="/images/dog_whisper_lowres.jpg?
1185178783" />

My rhtml is this:
<%= image_tag("/images/#{@asset.file_name}") %>

Am I missing something in the img_tag function?
I just noticed this today. The images render fine in a web browser,
but that certainly isn't what I want to have in my html!

Any ideas from anyone?

John Joyce
This topic is locked and can not be replied to.