I have images placed in assets/images. If i do localhost:3000/assets/
image I get the image in the browser, but
unfortunately, on the browser i am unable to view the images,
I am getting following errors in development mode. Haven’t tested yet
in production.
Started GET “/winecountry_part2.jpg” for 127.0.0.1 at 2011-11-26
12:56:40 -0800
ActionController::RoutingError (No route matches [GET] “/
winecountry_part2.jpg”):
Rendered /Users/jayparteek/.rvm/gems/[email protected]/gems/
actionpack-3.1.3/lib/action_dispatch/middleware/templates/rescues/
routing_error.erb within rescues/layout (0.6ms)
unfortunately, on the browser i am unable to view the images,
ActionController::RoutingError (No route matches [GET] “/
winecountry_part2.jpg”):
Look carefully at the routing error and you will see that you have not
got the same url as the one you entered manually. The problem is with
the link to the image in the view.
ActionController::RoutingError (No route matches [GET] “/
winecountry_part2.jpg”):
Look carefully at the routing error and you will see that you have not
got the same url as the one you entered manually. The problem is with
the link to the image in the view.
Excellent point. J.P, can you post the relevant chunk of whatever
view was trying to retrieve the file? Sounds like it was using a
hand-coded img tag for /winecountry_part2.jpg, rather than letting
Rails build it from some tag directive.
-Dave
–
LOOKING FOR WORK! What: Ruby (on/off Rails), Python, other modern
languages.
Where: Northern Virginia, Washington DC (near Orange Line), and remote
work.
See: davearonson.com (main) * codosaur.us (code) * dare2xl.com
(excellence).
Specialization is for insects. (Heinlein) - Have Pun, Will Babble!
(Aronson)
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.