title: How do I get an absolute URL for an asset in Rails 3.1?
body: <p><code>image_path</code> returns a path only (no host).</p>
  
  <p>The <code>url_for</code> helper won't accept a single path, so something like <code>url_for(image_path('image.png'))</code> wouldn't work. While the internal <code>url_for</code> in <code>ActionDispatch::Http::Url.url_for</code> would appear to do the trick (<a href="https://github.com/rails/rails/blob/master/actionpack/lib/action_dispatch/http/url.rb#L23" rel="noreferrer">source</a>), there doesn't seem to be a public interface for it.</p>
  
  <p>How should I go about doing it? Ultimately, it'd be nice to have a function like <code>image_url</code> that works like <code>url_for</code> does for routes so that I could call <code>image_url('image.png')</code> and get the absolute URL given all of the <code>default_url_options</code>.</p>