java regex: word chracters and white spaces -


i'd combine \w , \s classes. input should contain letters, numbers , whitespaces.

i've tried "[\\w\\s]" , "\\w\\s" , others. don't work.

thanks in advance!

you need (?u)[\p{alnum}\s], under java 7. otherwise gets both sets wrong, because works on ascii otherwise.


Comments

Popular posts from this blog

jquery - Invalid Assignment Left-Hand Side -

javascript - Preserving URL fragment through CAS sign-on -

asp.net mvc - Implementing normal user/pass, Twitter & Facebook auth -