Re: [Rails] Re: Missing template pages/layout only occasionally

2013-04-26 Thread Rick
I finally figured this out. I have an action that only renders html, but googlebot for instance wants text. So, I added this to the controller and everything works! before_filter :force_html_requests, :only => :show def force_html_requests request.format = :html end Rick On Monda

[Rails] Re: Missing template pages/layout only occasionally

2013-04-25 Thread Rick Cockerham
I finally figured this out. I have an action that only renders html, but googlebot for instance asks for text format. So, it tries to find action.text.erb which doesn't exist. I added this to my controller and everything works now. before_filter :force_html_requests, :only => :show def force

Re: [Rails] Re: Missing template pages/layout only occasionally

2012-11-26 Thread Jim Ruther Nill
On Tue, Nov 27, 2012 at 7:54 AM, Rick Cockerham wrote: > Excellent suggestion. From the page view I see this agent: > > Mozilla/5.0 (compatible; oBot/2.3.1; +http://filterdb.iss.net/crawler/) > > So, how do I setup my app to only accept html requests for those routes? > Or, just not fail when it

[Rails] Re: Missing template pages/layout only occasionally

2012-11-26 Thread Rick Cockerham
Excellent suggestion. From the page view I see this agent: Mozilla/5.0 (compatible; oBot/2.3.1; +http://filterdb.iss.net/crawler/) So, how do I setup my app to only accept html requests for those routes? Or, just not fail when it wants text? Thanks -- Posted via http://www.ruby-forum.com/.