3 ms·
Isnt there an i18n extension built on lib ICU in python , like Intl extension in PHP ? http://site.icu-project.org/ http://site.icu-project.org/ I'm sure ther
by camus2 13y ago
Isnt there an i18n extension built on lib ICU in python , like Intl extension in PHP ?
http://site.icu-project.org/ http://site.icu-project.org/
I'm sure there are better alternatives than just regexp to validate numbers, emails ,etc ...
- ygra 13y agoIt's not validation in this case, it's finding them in a body of text. For validation you generally have it easier because you often only deal with a single datum in a field (and thus string).
- masklinn 13y agoThe CLDR provides locale-specific formats for some datum types (IIRC numbers, dates, and durations). These formats can probably be reversed into the corresponding regular expression in order to perform locale-aware data detection. Of course further complexity is added in people being able to provide partial and context-dependent information, which is much harder to detect e.g. "December 3rd"