I'm trying to populate an iframe with some erb and I can't figure out how to create a route to the new controller.
class TestController < ApplicationController
def iframe
load_channels
render :partial => "report", :layout => "test"
end
end
This is in my webpage:
<iframe src="<%= url_for controller: 'test', action: 'iframe' %>" name="report"></iframe>"
I created a layout with basic html and erb.
I'm getting "no route matches" error. When I look at the routes.rb file it's one of the most confusing config files that I've ever seen.
How do I route to this controller?