/ Published in: Rails
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
def check_name_syntax !!((first_name + last_name).strip =~ /^[a-z '.-]+$/i) end