I have a feedback form in my Rails application. The feedback form requires initializing of the @support variable, and it should be visible on every page. The initialization is v
Rather than a global variable, you probably want to put something in the ApplicationController.
Either:
before_filter initialize_support def initialize_support @support = Support.new(:id => 1) end
Or:
helper_method support_form def support_form @support_form ||= Support.new(:id => 1) end