Hi to all,
i'd like to insert a validation inside my model about a mac address field. I've used this sintax but it's not working.
validates_format_of :mac_address, :with => /^((?:[-a-f0-9])+(?:[-a-f0-9])+(?:[-a-f0-9])+(?:[-a-f0-9])+(?:[-a-f0-9])+(?:[-a-f0-9]))$/i, :on => :create, :on => :update, :message => "MAC ADDRESS incorrect"
this code it's not working, i'm looking for a solution but i can't find out the problem...
Any help will be great...
Thanks
Andre