OK finally cracked it. Problem was with filters being run first in
application_controller.rb. The timezone_controller.rb set function was
being ignored as result of them. So

#routes.rb
  scope 'planbadmin' do
    resources :timezone do
      collection do
        post  :set
      end
    end
  end

#timezone_controller.rb
class TimezoneController < ApplicationController
  skip_before_filter :admin, :authorise

  def set
    session[:timezone] = params[:timezone]
    redirect_to(:controller => "planb")
  end
end

Just a quick one, if I don't have that redirect it barfs about a
missing template. Is there a neat way around it?

Thanks VERY much for all the help.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to