[Rails] Re: set user IP on create

2011-07-21 Thread Tomas R.
Tim Shaffer wrote in post #1012223: > Assigning it in the controller is probably the best bet: > > instance = Model.new(params[:model]) > instance.ip_address = request.ip_address I will do it then, thanks -- Posted via http://www.ruby-forum.com/. -- You received this message because you are su

[Rails] Re: set user IP on create

2011-07-21 Thread Tim Shaffer
Assigning it in the controller is probably the best bet: instance = Model.new(params[:model]) instance.ip_address = request.ip_address -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To view this discussion on the web visit https://grou

[Rails] Re: set user IP on create

2011-07-21 Thread Tomas R.
so how should I add the IP? assign it on the controller or maybe a hidden text field? -- Posted via http://www.ruby-forum.com/. -- 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 rubyonrails-talk@googl