Get the client IP address for the remote browser.
A simple method for getting the client IP address for the remote browser. Demo @ http://remoteip.herokuapp.com
$ npm install remoteip
var remoteip = require('remoteip');// Get the IP address for the user.var ipAddress = remoteip.get(req);
The client IP address is determined by the following:
- Check the x-forwarded-for HTTP header for a remote IP address.
- Check the req.connection.remoteAddress property.
Kory Becker http://www.primaryobjects.com