Tuesday, June 5, 2012

Images in public/ for error pages on Rails 3.1-3.2

For error pages found in public/ for a Rails 3.1 or 3.2 app, you might want to put a quick, simple image and reference it with the normal html img tag instead of any of Rails' fancy image_tag such and such.

Easy way that works:
1. Put images in public/images
2. Reference images like
<img src="/images/my-pic.jpg" />

1 comment:

  1. Do not use at house, kids. Wrong idea. Do not work in production mode.

    ReplyDelete

Please be considerate in what you say.