Method: String#to_alpha_numeric

Defined in:
lib/duffy/string.rb

#to_alpha_numericObject



53
54
55
# File 'lib/duffy/string.rb', line 53

def to_alpha_numeric
  self.to_s.gsub(/[^0-9a-zA-Z ]/, "").strip  # string with only a-z or A-Z or space, leading+trailing whitespace removed
end