-1

I have a list of all the countries based on their STD dialing codes for example +91 for India, +1 for USA,etc.

Based on dialing code, i can easily pick country. For example with +213 code, i can get Algeria as country.

But for +1 dialing code, i get more than one result(USA, Canada, Jamaica, Puerto Rico). Is there a way i can differentiate between them ?

Is there a way to manage them easily and get required result ?

If user is dialing +1 for Jamaica, he should get country Jamaica and not USA or any other.

Let me know

Dharmendra Yadav
  • 152
  • 1
  • 13

1 Answers1

2

If it has a 1, can you then put in some code to look at the next numbers, which should then indicate the country / island / region?

https://en.wikipedia.org/wiki/North_American_Numbering_Plan

Louise
  • 382
  • 1
  • 6
  • 16
  • can you please elaborate as +44 is code for United Kingdom, Guernsey, Isle of Man, Guernsey how can i differentiate these. – Cycl0n3 Jul 17 '20 at 12:16
  • For the united kingdom, the next 5 numbers following the +44 select the area. The channel islands are an area in exactly the same way as Central London. please see: https://www.ofcom.org.uk/phones-telecoms-and-internet/advice-for-consumers/advice/telephone-area-codes-tool. – Louise Aug 03 '20 at 14:04