Forum: Ruby on Rails Detecting Characters other the ASCII (Other than English)

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Ibrahim Mokdad (Guest)
on 2009-05-25 15:55
(Received via mailing list)
Dear all
I kinda need help on a project I'm working on; and I'm stuck on the
part were I have to detect any Unicode character in the text file;
will regular expressions "\w" work ?
thnx in advance
Marnen L. (Guest)
on 2009-05-25 20:27
Ibrahim Mokdad wrote:
> Dear all
> I kinda need help on a project I'm working on; and I'm stuck on the
> part were I have to detect any Unicode character in the text file;
> will regular expressions "\w" work ?
> thnx in advance

Why not . (period) in a regular expression?  That should do what you
want.

Best,
--
Marnen Laibow-Koser
http://www.marnen.org
removed_email_address@domain.invalid
timr (Guest)
on 2009-05-25 21:35
(Received via mailing list)
No /w will not work. And . (period) will not work either.
here is asdjflaw日本erjocd some text
the japanese within this text looks like this \346\227\245\346\234\254
in unicode.
it would not be matched by /w (letter or number set) or . (any
character).
each of the \ddd sets in the unicode character would be matched by a .
(period)

I am sure someone has a solution for this, but it is not me.

unicode geniuses HEEEEELLLLLP ください。
tim


On May 25, 9:27 am, Marnen Laibow-Koser <rails-mailing-l...@andreas-
This topic is locked and can not be replied to.