-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No validation of Country Code. #1
Comments
Is this up for grabs? |
Sure go ahead @cryptus-neoxys |
What would be the best approach for this?
|
If I'm not wrong, for geolocation, the user will have to grant location access which I think will harm the simplicity of the app. Maybe this can be used to get the country. $.get("http://ipinfo.io", function(response) {
console.log(response.city, response.country);
}, "jsonp"); One more thing, if the user pastes the number directly with a country code then, modify the selected country automatically. |
Yeah, similar issues regarding geolocation API requesting permission. Here's what I could think of as a better alternative: Use geolocation-db's ultimate free service to get the Country data and map that to country Phone code Country Code to Phone Code-JSON |
Looks good! |
Self-hosted alternative: |
Whatsapp Dynamic Link (wa.me) requires a country code in the beginning. Currently, no such validation is preventing it from redirecting.
The text was updated successfully, but these errors were encountered: