开发者

phone number prefix

How 开发者_StackOverflowwould I take a phone number like: 15556667777 and some how get its country code (prefix, the 1).. But, the issue is.. I will have to be able to get ANY numbers country prefix from any phone number. So whether it be UK, AU, US, any INTL country.


It seems like a pretty complicated parsing, with lots of exceptions. You should try some libraries for this purpose:

Google's library: http://code.google.com/p/libphonenumber/ (Java and JavaScript versions)

There's a python port: http://pypi.python.org/pypi/phonenumbers/3.3a1

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜