• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2004
  • Last Modified:

Jquery validation - regex greek text

Hello experts.
I'm using jquery validation plugin (http://www.position-absolute.com/)
The problem i have is to validate greek text.(allow greek text to pass the validation)
The plugin has  the regex for only letters:
"onlyLetter":{ "regex":/^[a-zA-Z\ \']+$/,
 "alertText":"* Only text allowed"},

I tried this one:
"onlyLetter":{"regex":/^[^\x00-\x80]+$/,
(from here:http://stackoverflow.com/questions/150033/regular-expression-to-match-non-english-characters)
This does not allow english(latin) letters.
Any help?
0
Panos
Asked:
Panos
  • 2
1 Solution
 
McOzCommented:
How about:

"onlyLetter":{"regex":/^([^\x00-\x80]|[a-zA-Z\ \'])+$/,
0
 
PanosAuthor Commented:
Hi McOz
It is working.
Thank you
0
 
PanosAuthor Commented:
thank you
regards
panos
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now