I am having a problem when the asset tag's timestamp does not apply when in use image_path. As a result, the image is not displayed. This only happens when I click on the hero.
the code:
<%= image_path 'notebook.png' %>
localhost result:
/images/notebook.png?1284326123
Heroku Result:
/images/notebook.png
Heroku Output:
-----> Heroku receiving push
-----> Rails app detected
-----> Detected Rails is not set to serve static_assets
Installing rails3_serve_static_assets... done
-----> Gemfile detected, running Bundler version 1.0.0
All dependencies are satisfied
Compiled slug size is 15.4MB
-----> Launching.... done
image_tagworks just fine. I suspect that it rails3_serve_static_assetsis my fault. Any ideas?
UPDATE
Checking the Heroku file system shows that Notebook.png exists.
$ heroku console
Ruby console for myapp.heroku.com
>> `ls public/images`
=> "<bunch of files>\nNotebook.png\n<bunch of other files>"
And there is a problem. My code referred to "laptop" where the file was called "Notebook". Localhost seems to be more permissive than Heroku.
source
share