Open spham opened 7 years ago
Yeah, would love to, but won't be able to until march 20, feel free to send a PR.
@spham could you give an example on how you would like the data? Already making a pull request so shouldn't be a problem to add your request too.
The calling code is already included, so if I understand E164 correctly you just want to add a +
before the calling code?
@spham The only difference I see on this and the already included property callingCode
is there is an +
before.
Is that correct?
The recommandation are here, and seems a lots of complex than + https://en.wikipedia.org/wiki/E.164
My bad, I can see there is also a National Destination Code
which is optional.
Will try to see if I can find a dataset with the needed data.
@uruloke, did you found something?
National Destination Code, looks a lot like the telephone number. An example here in my country:
International calling phone number = +5521980882233
+55 = Country Code (Brazil) 21980882233 = National Destination Code
21 = City Code (Rio de Janeiro) 980882233 = Local Phone Number
Local phone numbers can repeat on another city:
11 = City Code (São Paulo) 980882233 = Local Phone Number
That being said, take a look at those two datasets, please:
http://country.io/phone.json https://github.com/datasets/country-codes/blob/master/data/country-codes.csv
In this last one I found some other data we are missing, like Geoname ID and EDGAR.
@antonioribeiro http://country.io/phone.json This one seems a little inconsistence on when it wan't to use +
at th beginning and when not to.
The last one looks a lot more clean and the data is at least correct for my country.
@antonioribeiro my thoughts were more to integrate something like libphonenumber by google https://github.com/googlei18n/libphonenumber. There is an PHP port from giggsey https://github.com/giggsey/libphonenumber-for-php, and also an Laravel port of giggseys port https://github.com/Propaganistas/Laravel-Phone.
I haven't done anything yet to implement it, as I couldn't figure out how you loaded the data.
i think about new, issue
how to store in database ?
field (prefix, phone ) or field (phone e164 , i.e +337xxxxxxx )
country calling code display with [""] ["297"] ["93"] ["244"] ["1264"] ["358"] ["355"] ["376"] ["971"] ["54"] ["374"] ["1684"]......
please help me. how to remove [""] tag?
Hi Can you include Phone format in E164 as feature ?