ruby on rails - linking to html file in /public -
i have file 'maps.html' located in /public. loading index page contents follows: <%= link_to 'redirect_click_here', 'maps.html' %>. application.html.erb takes care of other necessary html elements page. result of clicking link sent /map/maps.html.
this logical: page hosting link in 'map' controller. still, want 'escape' controller , access public html file.
i realize kind of pointless request because put html file in app/views, it's completion's sake put forth request.
edit
one reason want include file /public/ directory don't want go through asset pipeline , inherit html document structure application.html.erb. going including html files include custom heads , don't want have replace contents of application.html.erb every time.
you should use '/maps.html' in link, knows in root public folder.
Comments
Post a Comment