Skip to content
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

added the cellular ip for ios #16

Closed

Conversation

ArshanKhanifar
Copy link

So I basically modified the method such that it will now return the cellular ip address, if the phone is not connected to wifi.

output: connected via wifi : x.x.x.x
output: connected via cell : x.x.x.x

This only works for ios.

@ArshanKhanifar
Copy link
Author

Please let me know if it has any problems.

@salbahra
Copy link
Owner

salbahra commented Nov 27, 2016

Is it possible to pass the interface back to the calling function? Therefore the app calling can decide how to use the IP (if it doesn't want to handle cell IP's, for example). Something like:

networkinterface.getIPAddress(function (ip,conn) { alert("connected via " + conn + ": " + ip); });

I don't have the time right now to spend on fixing this but it would be greatly appreciated improvement. I also would like to get this working for other platforms as well.

Thank you!

@salbahra
Copy link
Owner

This has been added by PR #17

@salbahra salbahra closed this Mar 31, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants