How can i get the html code create by a view into the controller
I need to save the html created into a view into a file something like
File.open( 'index.html', 'w' ){|file| file.write (The_view)}
How can i get the html code create by a view into the controller
I need to save the html created into a view into a file something like
File.open( 'index.html', 'w' ){|file| file.write (The_view)}
You can try the render_to_string method: http://api.rubyonrails.com/classes/ActionController/Base.html#M000475
Regards
GA Gorter escribió: