What Christian means is something like:
Put this in your app/views/layouts/application.html.erb:
<%= yield :refresh_tag %>
And then you will need to call this in a view:
<% content_for :refresh_tag do %>
> <meta http-equiv="refresh" content="5"/>
<% end %>
But this needs to be done in a view... unlike the requested
before_filter and after_filter.
You could set a variable in the before filter and wrap the code in an
if statement:
class ForumsController < ApplicationController
before_filter :refresh, :only => :show
# ...
private
def refresh
@refresh = true
end
end
Then in your application.html.erb:
<% if @refresh %>
> <meta http-equiv="refresh" content="5"/>
<% end %>
-----
Ryan Bigg
Freelancer
Skype: radarlistener
MSN & Gtalk:
radarl...@gmail.com