Passing the contents of a flash to a different controller

Is there a way to pass the contents of flash to a different
controller/action?
In the code below, /alpha/one will give me “The flash contains hello
world” but /alpha/three will have just “The flash contains” - any way
around this?

##############################################
class AlphaController < ApplicationController
def one
flash[:wibble] = ‘hello world’
redirect_to :action => ‘two’
end
def two
render_text "The flash contains " + flash[:wibble]
end
def three
flash[:wibble] = ‘hello next world’
redirect_to :controller => ‘beta’, :action => ‘foo’
end
end
##############################################
class BetaController < ApplicationController
def foo
render_text "The flash contains " + flash[:wibble]
end
end
##############################################

raghus wrote:

redirect_to :action => 'two'

class BetaController < ApplicationController
def foo
render_text "The flash contains " + flash[:wibble]
end
end
##############################################

This should work. Are you sure you actual code doesn’t
contain an extra redirect?


We develop, watch us RoR, in numbers too big to ignore.