Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Rails Blogger Tutorial - Strong Parameters #606
So I ran into a problem following http://tutorials.jumpstartlab.com/projects/blogger.html#i1:-form-based-workflow
The attr_accessible doesn't work anymore.
So I read up on it here:
Looks like in Rails 4, this has been abstracted to a gem.
So I added
Added to Gemfile.
This gem adds the ability allow certain users to create / update certain fields within your model.
So -- in my articles model I added
and in my articles_controller I added a method called article_params:
and my create method now looks like this:
Wasn't sure if you guys were looking for updates to this tutorial for Rails 4, but figured I'd throw it out there.
I sure learned something new :)
The tutorial is explicitly for rails 3.2 right now. I want to update it for 4, but have not yet.
On Sun, Jul 14, 2013 at 12:48 AM, Maksim Pecherskiy