myIpAddress: refactor to use a different "technique"

Got the idea from: http://stackoverflow.com/a/7074687/376773