is it possible to store a field of type file_column in the session? Rails crashes on me every time i try to do something like the following: @session[:newpost] = @params[:post] however if i assign each field of @params[:post[ except for @params[:post]["image"] i have no problems. Is there something that should be done to allow the file in the session? thanks adam
Adam Denenberg <straightflush@...> writes:> > is it possible to store a field of type file_column in the session? > Rails crashes on me every time i try to do something like the > following: > > <at> session[:newpost] = <at> params[:post] > > however if i assign each field of <at> params[:post[ except for > <at> params[:post]["image"] i have no problems. Is there something that > should be done to allow the file in the session? > > thanks > adam >in application.rb you need to make sure the model is specified for any models you want to store in session. class ApplicationController < ActionController:::Base model :file_column end
most helpful, thank you. adam On 1/13/06, Jason Cartwright <jcartwright@enspiredsoftware.com> wrote:> Adam Denenberg <straightflush@...> writes: > > > > > is it possible to store a field of type file_column in the session? > > Rails crashes on me every time i try to do something like the > > following: > > > > <at> session[:newpost] = <at> params[:post] > > > > however if i assign each field of <at> params[:post[ except for > > <at> params[:post]["image"] i have no problems. Is there something that > > should be done to allow the file in the session? > > > > thanks > > adam > > > > in application.rb you need to make sure the model is specified for any models > you want to store in session. > > class ApplicationController < ActionController:::Base > model :file_column > end > > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >