Created
June 3, 2020 12:59
-
-
Save kenshinman/5f971a1291dea410c9488ad9a383a863 to your computer and use it in GitHub Desktop.
Regex for all Nigerian GSM phone numbers including +234 prefix, and 234 prefix
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/^(\+234|234|0)(701|702|703|704|705|706|707|708|709|802|803|804|805|806|807|808|809|810|811|812|813|814|815|816|817|818|819|909|908|901|902|903|904|905|906|907)([0-9]{7})$/ | |
2347031546361 //valid | |
+2347031546361 //valid | |
07031546361 //valid | |
7031546361 //invalid |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment