I\'m using Rails 3.1. I\'m trying to figure this out, and to my surprise, it is starting to seem that rails does not come with this method at all. Maybe im wrong.
Ca
put this in application_helper.rb
application_helper.rb
def asset_url asset "#{request.protocol}#{request.host_with_port}#{asset_path(asset)}" end
then you can use asset_url in your views.
asset_url