Agile Web Development

Build it. Launch it. Love it.

Validates Numericality Of

Extends the validates_numericality_of validation by adding :gt, :gte:, :lt, :lte, :eq, :even, :odd conditions

Vitals

Home http://www.railtie.net/articles/2006/01/27/defining-numericality
License
Tags Tag_red Numericality validates
Rating (3 votes)
Owner Bob Silva
Created 25 May 2006

Comments

  • Avatar
    Kevin Olbrich
    23 August 2006

    Numbers are converted to integers before doing comparisons, this can cause problems with numbers being truncated improperly.

  • Avatar
    viktor tron
    15 December 2007

    this is obsolete with rails 2.0 as far as I can tell

Add a comment