30 Mar '12, 8am

omgbloglol - Improved validations in Rails 3:

Improved validations in Rails 3 Quite sorry about not getting another post up sooner; I’ve been very busy lately with a few different things (some of which shall be revealed very soon!). Today I want to talk about validations. Validations received quite a bit of love in Rails 3, but if you don’t go looking for the new shiny features, you won’t find them. The old API is still around, so nothing will break if you try them, but there is also a variation on that theme: validates :login, :presence => true, :length => {:minimum => 4}, :uniqueness => true, :format => { :with => /[A-Za-z0-9]+/ } This new form is excellent since you can compress what would have previously been 4 lines of code into 1, making it dead simple to see all the validations related to a single attribute all in one place. The valid keys/value types for this form are: :presence => true :uniqueness => true :nu...

Full article: http://omgbloglol.com/post/392895742/improved-validations...

Tweets

Rails 3.2.3 was released!!!

weblog.rubyonrails.org 30 Mar '12, 10pm

Rails 3.2.3 also introduces a new option that allows you to control the behavior of remote forms when it comes to authenti...

14 Bare Minimum Security Checks Before Releasin...

railsinside.com 30 Mar '12, 1am

When you upload your latest app to a production Web server and open it up to the world, you're really throwing your app to...

Rails 3.2.3.rc2 was released

weblog.rubyonrails.org 29 Mar '12, 4pm

Rails 3.2.3 introduced a new option that allows you to control the behavior of remote forms when it comes to authenticity_...

Rails 3.0’s ActiveModel: How To Give Ruby Class...

rubyinside.com 29 Mar '12, 1pm

In extracting the model-building parts of ActiveRecord, ActiveModel makes it possible to add model-like behavior to any Ru...

"Observers" class UserObserver < ActiveRecord::...

guides.rubyonrails.org 11 Apr '12, 11pm

Database constraints and/or stored procedures make the validation mechanisms database-dependent and can make testing and m...

Woohooo! <3 <3

cathaycineplexes.com.sg 06 Apr '12, 2am

This 3D re-release of the 1997 film, starts out as a present day undersea expedition in search of a valuable diamond aboar...

WHAT'S NEW IN EDGE #RAILS

afreshcup.com 02 Apr '12, 12pm

is Mike Gunderloy's software development weblog, covering Ruby on Rails and whatever else I find interesting in the univer...

Railscasts - Rails 2.3 Extras:

railscasts.com 31 Mar '12, 10pm

# find in batches Product.count Product.find_in_batches(:batch_size => 10) do |batch| puts "Products in batch: #{batch.siz...

Walken on Rails

rubyflow.com 01 Apr '12, 8pm

Walken on Rails Posted by laserlemon on April 01, 2012 — 1 comment For quite a while now, Collective Idea has been working...

Build Database Of Ruby Programmers: We would li...

workingwithrails.com 03 Apr '12, 9pm

Set the extra attribute in a join model with an association of has_many :through without creating two records for the join...

Am I missing something or is this page laughabl...

guides.rubyonrails.org 01 Apr '12, 2am

The very first parameter, a string, is the text of the link which appears on the page. The second parameter, the options h...

Rails isn't for beginners

rubyflow.com 03 Apr '12, 7pm

Rails isn't for beginners Posted by stephenballnc on April 03, 2012 — 0 comments I've just written a post on Rake Routes: ...